-
-
Save tigefabot/ae84ebd87eb8da543d67760d151d9a0d to your computer and use it in GitHub Desktop.
My quick command snippets (ffmpeg)
This file contains hidden or 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
| ///////////////////////////////////////////// FFMPEG snippets //////////////////////////////////////////////////// | |
| ffmpeg -f rawvideo -vcodec rawvideo -s 1920x1080 -r 30 -pix_fmt yuv420p -i crowdRun_D.yuv -codec:v v210 output.mov | |
| ffmpeg -i input.avi -c:v libx264 -crf 19 -preset slow -c:a libfaac -b:a 192k -ac 2 out.mp4 | |
| ================================================================================================================== | |
| Decode 10 bit mov capture as yuv v210 | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -i -r 30 Capture0000.mov -r 30 -codec:v v210 output.yuv | |
| ================================================================================================================== | |
| ================================================================================================================== | |
| Decode 10 bit mov capture as yuv | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -i Capture0002.mov -vcodec rawvideo -s 1920x1080 -r 30 -pix_fmt yuv420p -vtag YV12 output.yuv | |
| ================================================================================================================== | |
| ================================================================================================================== | |
| Decode 10 bit mkv and mov capture as yuv | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -i ducati.mov -vcodec rawvideo -s 1920x1080 -r 30 -codec:v v210 output.yuv | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -i jellyfish-3-mbps-hd-hevc-10bit.mkv -vcodec rawvideo -s 1920x1080 -r 30 -codec:v v210 output.yuv | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -s 1920x1080 -vcodec v210 -i crowd0-9_1920x1080_25Hz_10bit.v210 -codec:v v210 output.mov | |
| ================================================================================================================== | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| Streaming with ffmpeg | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| ffmpeg -s 1920x1080 -vcodec v210 -i jelly_fish.yuv -ar 8000 -f mulaw -f rtp rtp://127.0.0.1:1235 | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| Convert V210 to 422 p 10 bit stream | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| ffmpeg -vcodec rawvideo -s 1920x1080 -r 30 -codec:v v210 -i crowd.v210 -f rawvideo -vcodec rawvideo -s 1920x1080 -r 30 -pix_fmt yuv422p10le output1.yuv | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| Convert to uyvy422 | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| ffmpeg -i xx%d.jpg -s 1280x720 -pix_fmt uyvy422 xx%d.yuv | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| Find supported formats of FFMPEG | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| ================================================================================================================== | |
| Cutting Video As Frames | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -ss 3 -i capture_21Aug_chessboard_straight.mp4 -c copy -t 14 output.mp4 | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ================================================================================================================== | |
| ================================================================================================================== | |
| Converting video into images(frame by frame) | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ffmpeg -i output.mp4 xx%d.jpg | |
| ------------------------------------------------------------------------------------------------------------------ | |
| ================================================================================================================== | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| /****************************************************************************************************************/ | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| ================================================================================================================== | |
| FFMPEG library based application | |
| ================================================================================================================== | |
| 1) Makefile creation | |
| ------------------------------------------------------------------------------------------------------------------ | |
| 2) gcc decode_video.c -lavdevice -lavformat -lavfilter -lavcodec -lswresample -lswscale -lavutil -lpthread -lm -ldl -lz | |
| ---------------------------------------------------------------------------------------------------------------------------- | |
| For Windows: | |
| gcc -I local/include -L local/lib decode_video.c -lavdevice -lavformat -lavfilter -lavcodec -lswresample -lswscale -lavutil -lpthread -lm -ldl -lz | |
| ---------------------------------------------------------------------------------------------------------------------------- | |
| ================================================================================================================== | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| /****************************************************************************************************************/ | |
| ////////////////////////////////////////////////////////////////////////////////////////////////////////////////// |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment