Last active
March 29, 2019 17:23
-
-
Save zealot128/c6c0bc2107d81fb0e7a0c3e652ad6fe2 to your computer and use it in GitHub Desktop.
ffmpeg scripts
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
# Screencast on OSX | |
ffmpeg -r 30 -f avfoundation -capture_cursor 1 -capture_mouse_clicks 1 -i "1:0" out2.mp4 | |
# Framerate 30 | |
# Cursors + Clicks | |
# "1:0" -> first screen and microphone | |
# list all devices for above | |
ffmpeg -f avfoundation -list_devices true -i "" | |
## MACBOOK PRO Retina problems | |
# Using retina screen, I had a lot of microphone stutter, seems to be the pixel format | |
# force with -pix_fmt yuv420p | |
ffmpeg -r 30 -f avfoundation -capture_cursor 1 -capture_mouse_clicks 1 -i "1:0" \ | |
-pix_fmt yuv420p -preset veryfast -c:v libx264 -profile:v main -level 4 screen.mp4 | |
# show video information | |
ffprobe -show_format -print_format json $1 2> /dev/null | |
# okish conversion for older videos: | |
# * keep meta data | |
# * libfaac, also aac or faac, depending on what is available | |
ffmpeg -i INPUT_FILE -preset veryfast -c:v libx264 -profile:v main -level 4 -c:a libfaac -q:a 100 -crf 25 -map_metadata 0 OUTPUT_FILE | |
# list all encodes | |
ffmpeg -encoders | |
## Reverse GoPro at bike handler - merge all video parts and turn video 180deg | |
## used all *.MP4 files in current folder | |
ffmpeg -f concat -safe 0 -i <(for f in ./*.MP4; do echo "file '$PWD/$f'"; done) -metadata:s:v rotate="180" -c copy output.MP4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment