ref: eed5e27c98eaa435db4a4c96955b3b131d2db78f
parent: 93ba76d2649f29277de1e383d7469525364aaec8
author: qwx <qwx@sciops.net>
date: Fri Apr 1 19:27:55 EDT 2022
add w520rec: recording with facecam and hardware audio mixer on the w520 - soft cursor to have it visible - automatic config of the internal cam - trick to leave the cam window always on top, like bar(1); requires sticky mode if used with riow - recording h264 + aac, made into mp4 on linux with ffmpeg - hj264 quality parameters are a bit high, but whatever, we get close to 60 fps
--- /dev/null
+++ b/bin/w520rec
@@ -1,0 +1,30 @@
+#!/bin/rc
+# no noise gate/suppression for the mic
+# everything plugged into mixer, mixer's usb card on w500, recording
+# on w520 using w500's audio
+
+echo hwgc soft >/dev/vgactl
+echo blanktime 0 >/dev/mousectl
+
+window -r 1730 839 1920 1055 'label cam
+ nusb/cam 7
+ cat <<! >/dev/cam7.1/ctl
+format 320x240
+fps 30
+backlight-compensation 1
+brightness 20
+contrast 95
+saturation 40
+sharpness 7
+gamma 200
+!
+ { while() sleep 2 && echo top >/dev/wctl} &
+ camv /dev/cam7.1'
+window -scroll 'echo slay hj264 aacenc cam ''|'' rc; rc'
+
+echo 'proceed?'
+read -n 1 >/dev/null
+
+rimport -u qwx w500 '#u' /n/c
+window -m rc -c 'audio/aacenc -b </n/c/audioin >/tmp/rec.`{date -t}^.aac'
+video/hj264 -f 50 -k 1000 -Q 50 /dev/screen > /tmp/rec.^`{date -t}^.264