Last active
May 4, 2018 18:52
-
-
Save nk23x/8619747 to your computer and use it in GitHub Desktop.
ffmpeg examples
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
## mp4 to ogv | |
ffmpeg -i VIDEO.mp4 -acodec vorbis -aq 3 -strict -2 -qscale:v 18 VIDEO.ogv | |
## PAL VIDEO CD (VCD) | |
ffmpeg -i /path/file.avi -target pal-vcd -s 352x192 -padtop 32 -padbottom 32 -ab 128 /path/output.mpg | |
vcdimager -t vcd2 -l "LABEL" -c videocd.cue -b videocd.bin output.mpg | |
cdrecord -dao cuefile=videocd.cue speed=8 (..) | |
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/bash | |
while true; do | |
if [[ $(df / -m --output=avail | grep -v Avail) -gt "500" ]]; then | |
ffmpeg -an \ | |
-f video4linux2 \ | |
-i /dev/video1 \ | |
-video_size 320x240 \ | |
-t 00:10:00 \ | |
-framerate 8 \ | |
-vf "hflip,vflip,format=yuv420p" \ | |
-metadata:s:v rotate=0 \ | |
-qscale:v 6 \ | |
-n \ | |
-loglevel quiet \ | |
/tmp/$(date +%s-%N).ogv | |
sleep 2s | |
else | |
exit 1 | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment