Created
May 4, 2020 04:20
-
-
Save cjbarroso/4d6cfc5ce8d8017fa8a61f5eac8eedb8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# | |
# videolog.sh | |
# Copyright (C) 2020 charlie <carlos@cjbarroso.com> | |
# | |
# Distributed under terms of the MIT license. | |
# Records a 10 seconds work log for posterity | |
# To be used with voice commands from Mycroft | |
OUTDIR="${HOME}/Audiologs" | |
FILENAME=$(date +%Y%m%d%H%M%S).mp4 | |
LENGTH=10 | |
LINE="#duplicate{dst=display,dst=\"transcode{vcodec=mp4v,acodec=mpga,vb=800,ab=128,deinterlace}:file{dst=${OUTDIR}/${FILENAME}}\"}" | |
echo Recording to $FILENAME for $LENGTH seconds... | |
LC_NUMERIC=C timeout ${LENGTH} cvlc v4l2:///dev/video0 :input-slave=pulse:// --sout $LINE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment