-
-
Save meoww-bot/33f2b38a8376b5895d045f4eacf2b88d to your computer and use it in GitHub Desktop.
Revisions
-
protrolium revised this gist
Aug 28, 2021 . 1 changed file with 3 additions and 4 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -58,10 +58,6 @@ combine the two streams together (new audio with originally exisiting video)<br> or add an offset to audio<br> `ffmpeg -i 36.MOV -itsoffset -0.25 -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> - - - You say you want to "extract audio from them (mp3 or ogg)". But what if the audio in the mp4 file is not one of those? you'd have to transcode anyway. So why not leave the audio format detection up to ffmpeg? @@ -128,6 +124,9 @@ concat demuxer<br> <br> `$ ffmpeg -f concat -safe 0 -i mylist.txt -c copy output.mp4` ## Rotate Video by editing metadata (without re-encoding). `ffmpeg -i input.m4v -map_metadata 0 -metadata:s:v rotate="90" -codec copy output.m4v` ## Split a Video into Images `$ ffmpeg -i video.flv image%d.jpg` -
protrolium revised this gist
Aug 28, 2021 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -58,6 +58,10 @@ combine the two streams together (new audio with originally exisiting video)<br> or add an offset to audio<br> `ffmpeg -i 36.MOV -itsoffset -0.25 -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> ## Rotate Video by editing metadata (without re-encoding). <br> `ffmpeg -i input.m4v -map_metadata 0 -metadata:s:v rotate="90" -codec copy output.m4v` - - - You say you want to "extract audio from them (mp3 or ogg)". But what if the audio in the mp4 file is not one of those? you'd have to transcode anyway. So why not leave the audio format detection up to ffmpeg? -
protrolium revised this gist
Feb 19, 2021 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -221,6 +221,10 @@ check for streams that you want (video/audio). be sure to convert/specify DTS 6 `ffmpeg -i source.mov -i watermark.png -filter_complex "overlay=x=(main_w-overlay_w)/2:y=(main_h-overlay_h)/2" output.mp4` <br> ### Reverse a video `ffmpeg -i vid.mp4 -vf reverse reversed.mp4` <br> ### Concat a video with a reversed copy of itself for ping-pong looping effect `ffmpeg -i input.mp4 -filter_complex "[0:v]reverse,fifo[r];[0:v][r] concat=n=2:v=1 [v]" -map "[v]" output.mp4` - - - -
protrolium revised this gist
Oct 31, 2020 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -109,6 +109,7 @@ A batch file version of the same command would be:<br> ## Extract Single Image from a Video at Specified Frame `$ vf [ss][filename][outputFileName]`<br> where `vf` is a custom bash script as follows:<br> `$ ffmpeg -ss $1 -i $2 -qmin 1 -q:v 1 -qscale:v 2 -frames:v 1 -huffman optimal $3.jpg`<br> <br> -
protrolium revised this gist
Oct 31, 2020 . 1 changed file with 3 additions and 3 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -46,6 +46,9 @@ The -i option in the above command is simple: it is the path to the input file. ## Replace Audio on a Video without re-encoding. **preferred method**<br> `ffmpeg -i INPUT.mp4 -i AUDIO.wav -shortest -c:v copy -c:a aac -b:a 256k OUTPUT.mp4` strip audio stream away from video<br> `ffmpeg -i INPUT.mp4 -codec copy -an OUTPUT.mp4` @@ -55,9 +58,6 @@ combine the two streams together (new audio with originally exisiting video)<br> or add an offset to audio<br> `ffmpeg -i 36.MOV -itsoffset -0.25 -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> - - - You say you want to "extract audio from them (mp3 or ogg)". But what if the audio in the mp4 file is not one of those? you'd have to transcode anyway. So why not leave the audio format detection up to ffmpeg? -
protrolium revised this gist
Oct 31, 2020 . 1 changed file with 3 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -51,9 +51,11 @@ strip audio stream away from video<br> combine the two streams together (new audio with originally exisiting video)<br> `ffmpeg -i 36.MOV -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> or add an offset to audio<br> `ffmpeg -i 36.MOV -itsoffset -0.25 -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> **preferred method**<br> `ffmpeg -i INPUT.mp4 -i AUDIO.wav -shortest -c:v copy -c:a aac -b:a 256k OUTPUT.mp4` - - - -
protrolium revised this gist
Oct 30, 2020 . 1 changed file with 2 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -18,7 +18,8 @@ Convert any MP3 file to WAV 16khz mono 16bit:<br> Convert any MP3 file to WAV 20khz mono 16bit for ADDAC WAV Player:<br> `ffmpeg -i 111.mp3 -acodec pcm_s16le -ac 1 -ar 22050 out.wav`<br> **cd into dir for batch process:**<br> `for i in *.mp3; do ffmpeg -i "$i" -acodec pcm_s16le -ac 1 -ar 22050 "${i%.mp3}-encoded.wav"; done` Picking the 30 seconds fragment at an offset of 1 minute:<br> -
protrolium revised this gist
Oct 30, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -6,6 +6,9 @@ Minimal example: transcode from MP3 to WMA:<br> You can get the list of supported formats with:<br> `ffmpeg -formats` You can get the list of installed codecs with:<br> `ffmpeg -codecs` Convert WAV to MP3, mix down to mono (use 1 audio channel), set bit rate to 64 kbps and sample rate to 22050 Hz:<br> `ffmpeg -i input.wav -ac 1 -ab 64000 -ar 22050 output.mp3`<br> -
protrolium revised this gist
Oct 30, 2020 . 1 changed file with 1 addition and 4 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -148,10 +148,6 @@ concat demuxer<br> ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> ## Simple FLAC convert `ffmpeg -i audio.xxx -c:a flac audio.flac` @@ -205,6 +201,7 @@ make a grayscale version and scale to 640x480 ### Convert MP4 to WEBM `ffmpeg -i input.mp4 -c:v libvpx-vp9 -crf 31 -b:v 1M output.webm`<br> [more info](http://trac.ffmpeg.org/wiki/Encode/VP9)<br> ### Convert MKV to MP4 `ffmpeg -i file.mkv`<br> -
protrolium revised this gist
Oct 30, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -203,6 +203,9 @@ Example:<br> <br> make a grayscale version and scale to 640x480 ### Convert MP4 to WEBM `ffmpeg -i input.mp4 -c:v libvpx-vp9 -crf 31 -b:v 1M output.webm`<br> ### Convert MKV to MP4 `ffmpeg -i file.mkv`<br> <br> -
protrolium revised this gist
Sep 4, 2020 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -140,7 +140,9 @@ concat demuxer<br> ## Evaluate which ratio to apply for scaling, then scale with the requisite amount of padding `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=iw*min(1280/iw\,720/ih):ih*min(1280/iw\,720/ih), pad=1280:720:(1280-iw*min(1280/iw\,720/ih))/2:(720-ih*min(1280/iw\,720/ih))/2" test.mp4` <br> <br> 1920 version<br> <br> `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=iw*min(1920/iw\,1080/ih):ih*min(1920/iw\,1080/ih), pad=1920:1080:(1920-iw*min(1920/iw\,1080/ih))/2:(1080-ih*min(1920/iw\,1080/ih))/2" test.mp4` ## Convert .mov (JPEG-A or other codec) to H264 .mp4 -
protrolium revised this gist
Sep 4, 2020 . 1 changed file with 4 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -138,7 +138,10 @@ concat demuxer<br> `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=720:-2" test.mp4` ## Evaluate which ratio to apply for scaling, then scale with the requisite amount of padding `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=iw*min(1280/iw\,720/ih):ih*min(1280/iw\,720/ih), pad=1280:720:(1280-iw*min(1280/iw\,720/ih))/2:(720-ih*min(1280/iw\,720/ih))/2" test.mp4` <br> 1920 version<br> `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=iw*min(1920/iw\,1080/ih):ih*min(1920/iw\,1080/ih), pad=1920:1080:(1920-iw*min(1920/iw\,1080/ih))/2:(1080-ih*min(1920/iw\,1080/ih))/2" test.mp4` ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> -
protrolium revised this gist
Sep 4, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -137,6 +137,9 @@ concat demuxer<br> ## Guarantee aspect ratio from image sequence `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=720:-2" test.mp4` ## Evaluate which ratio to apply for scaling, then scale with the requisite amount of padding `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=iw*min(1280/iw\,720/ih):ih*min(1280/iw\,720/ih), pad=1280:720:(1280-iw*min(1280/iw\,720/ih))/2:(720-ih*min(1280/iw\,720/ih))/2" test.mp4`gi ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> -
protrolium revised this gist
Sep 4, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -134,6 +134,9 @@ concat demuxer<br> ## Convert image sequence of many different sizes and conform to specific frame size `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=max(1280\,a*720):max(1280\,720/a),crop=1280:720" test.mp4` ## Guarantee aspect ratio from image sequence `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=720:-2" test.mp4` ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> -
protrolium revised this gist
Sep 4, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -131,6 +131,9 @@ concat demuxer<br> ## Convert non-sequentially named Images in a directory `$ ffmpeg -framerate 30 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p gan-1.mov`<br> ## Convert image sequence of many different sizes and conform to specific frame size `$ ffmpeg -i image-%04d.jpg -c:v libx264 -pix_fmt yuv420p -vf "scale=max(1280\,a*720):max(1280\,720/a),crop=1280:720" test.mp4` ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> -
protrolium revised this gist
Aug 21, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -199,6 +199,9 @@ check for streams that you want (video/audio). be sure to convert/specify DTS 6 ### Add Watermark overlay (png) to the center of a video `ffmpeg -i source.mov -i watermark.png -filter_complex "overlay=x=(main_w-overlay_w)/2:y=(main_h-overlay_h)/2" output.mp4` <br> ### Concat a video with a reversed copy of itself for ping-pong looping effect `ffmpeg -i input.mp4 -filter_complex "[0:v]reverse,fifo[r];[0:v][r] concat=n=2:v=1 [v]" -map "[v]" output.mp4` - - - more commands<br> http://www.catswhocode.com/blog/19-ffmpeg-commands-for-all-needs -
protrolium revised this gist
Jun 28, 2020 . 1 changed file with 6 additions and 6 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -110,12 +110,12 @@ ss offset = frame number divided by FPS of video = the decimal (in milliseconds) ## Merge Multiple Videos concat demuxer<br> `$ cat mylist.txt`<br> `file '/path/to/file1'`<br> `file '/path/to/file2'`<br> `file '/path/to/file3'`<br> <br> `$ ffmpeg -f concat -safe 0 -i mylist.txt -c copy output.mp4` ## Split a Video into Images `$ ffmpeg -i video.flv image%d.jpg` -
protrolium revised this gist
Jun 28, 2020 . 1 changed file with 6 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -109,9 +109,13 @@ where `vf` is a custom bash script as follows:<br> ss offset = frame number divided by FPS of video = the decimal (in milliseconds) ffmpeg needs i.e. 130.5<br> ## Merge Multiple Videos concat demuxer<br> `$ cat mylist.txt file '/path/to/file1' file '/path/to/file2' file '/path/to/file3' $ ffmpeg -f concat -safe 0 -i mylist.txt -c copy output.mp4` ## Split a Video into Images `$ ffmpeg -i video.flv image%d.jpg` -
protrolium revised this gist
Jun 28, 2020 . 1 changed file with 0 additions and 3 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -113,9 +113,6 @@ ss offset = frame number divided by FPS of video = the decimal (in milliseconds) file names in folder, if they contain spaces, must be properly escaped <br> `ls * | perl -ne 'print "file $_"' | ffmpeg -f concat -i - -c copy merged.mp4` ## Split a Video into Images `$ ffmpeg -i video.flv image%d.jpg` -
protrolium revised this gist
Jun 28, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -113,6 +113,9 @@ ss offset = frame number divided by FPS of video = the decimal (in milliseconds) file names in folder, if they contain spaces, must be properly escaped <br> `ls * | perl -ne 'print "file $_"' | ffmpeg -f concat -i - -c copy merged.mp4` ## Concatenate with crossfade `ffmpeg -i 1.mp4 -i 2.mp4 -filter_complex xfade=offset=4.5:duration=1 output.mp4` ## Split a Video into Images `$ ffmpeg -i video.flv image%d.jpg` -
protrolium revised this gist
May 30, 2020 . No changes.There are no files selected for viewing
-
protrolium revised this gist
Apr 23, 2020 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -47,6 +47,8 @@ strip audio stream away from video<br> combine the two streams together (new audio with originally exisiting video)<br> `ffmpeg -i 36.MOV -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> or add an offset to audio<br> `ffmpeg -i 36.MOV -itsoffset -0.25 -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> or<br> `ffmpeg -i INPUT.mp4 -i AUDIO.wav -shortest -c:v copy -c:a aac -b:a 256k OUTPUT.mp4` -
protrolium revised this gist
Apr 23, 2020 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -46,6 +46,8 @@ strip audio stream away from video<br> `ffmpeg -i INPUT.mp4 -codec copy -an OUTPUT.mp4` combine the two streams together (new audio with originally exisiting video)<br> `ffmpeg -i 36.MOV -i 36.wav -map 0:v -map 1:a -c copy -y 36-encoded.mov`<br> or<br> `ffmpeg -i INPUT.mp4 -i AUDIO.wav -shortest -c:v copy -c:a aac -b:a 256k OUTPUT.mp4` - - - -
protrolium revised this gist
Apr 23, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -172,7 +172,7 @@ If you want to cut off section from the beginning, simply drop -t 00:00:10 from #### reduce filesize Example:<br> `ffmpeg -i input.mov -vcodec libx264 -crf 24 output.mp4`<br> <br> It reduced a 100mb video to 9mb.. Very little change in video quality. -
protrolium revised this gist
Apr 9, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -118,7 +118,7 @@ file names in folder, if they contain spaces, must be properly escaped <br> `$ ffmpeg -r 1/5 -i image-%03d.png -c:v libx264 -vf fps=25 -pix_fmt yuv420p test.mp4`<br> ## Convert Single Image into a Video `$ ffmpeg -loop 1 -i image.png -c:v libx264 -t 60 -pix_fmt yuv420p -vf scale=1920:1080 out.mp4`<br> ## Convert non-sequentially named Images in a directory `$ ffmpeg -framerate 30 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p gan-1.mov`<br> -
protrolium revised this gist
Apr 9, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -117,6 +117,9 @@ file names in folder, if they contain spaces, must be properly escaped <br> `$ ffmpeg -i image-%03d.png -c:v libx264 -pix_fmt yuv420p test.mp4`<br> `$ ffmpeg -r 1/5 -i image-%03d.png -c:v libx264 -vf fps=25 -pix_fmt yuv420p test.mp4`<br> ## Convert Single Image into a Video `ffmpeg -loop 1 -i image.png -c:v libx264 -t 60 -pix_fmt yuv420p -vf scale=1920:1080 out.mp4` ## Convert non-sequentially named Images in a directory `$ ffmpeg -framerate 30 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p gan-1.mov`<br> -
protrolium revised this gist
Apr 7, 2020 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -120,6 +120,9 @@ file names in folder, if they contain spaces, must be properly escaped <br> ## Convert non-sequentially named Images in a directory `$ ffmpeg -framerate 30 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p gan-1.mov`<br> ## Convert .mov (JPEG-A or other codec) to H264 .mp4 `ffmpeg -i input.mov -vcodec libx264 -pix_fmt yuv420p output.mp4`<br> ## Convert mp4 to webm `$ ffmpeg -i example.mp4 -f webm -c:v libvpx -b:v 1M -acodec libvorbis example.webm -hide_banner`<br> [more info](http://www.bugcodemaster.com/article/convert-videos-webm-format-using-ffmpeg) -
protrolium revised this gist
Sep 6, 2019 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -117,6 +117,9 @@ file names in folder, if they contain spaces, must be properly escaped <br> `$ ffmpeg -i image-%03d.png -c:v libx264 -pix_fmt yuv420p test.mp4`<br> `$ ffmpeg -r 1/5 -i image-%03d.png -c:v libx264 -vf fps=25 -pix_fmt yuv420p test.mp4`<br> ## Convert non-sequentially named Images in a directory `$ ffmpeg -framerate 30 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p gan-1.mov`<br> ## Convert mp4 to webm `$ ffmpeg -i example.mp4 -f webm -c:v libvpx -b:v 1M -acodec libvorbis example.webm -hide_banner`<br> [more info](http://www.bugcodemaster.com/article/convert-videos-webm-format-using-ffmpeg) -
protrolium revised this gist
Sep 5, 2019 . 1 changed file with 3 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -25,6 +25,9 @@ In seconds<br> In HH:MM:SS format<br> `ffmpeg -i input.mp3 -ss 0:01:00 -t 0:00:30 output.wav` Split an audio stream at specified segment rate (e.g. 3 seconds)<br> `ffmpeg -i somefile.mp3 -f segment -segment_time 3 -c copy out%03d.mp3`<br> ## Extract Audio `ffmpeg -i input-video.avi -vn -acodec copy output-audio.aac ` -
Gavin Gamboa revised this gist
Aug 16, 2019 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -111,8 +111,8 @@ file names in folder, if they contain spaces, must be properly escaped <br> ## Convert Images into a Video `$ ffmpeg -f image2 -i image%d.jpg imagestovideo.mp4`<br> `$ ffmpeg -i image-%03d.png -c:v libx264 -pix_fmt yuv420p test.mp4`<br> `$ ffmpeg -r 1/5 -i image-%03d.png -c:v libx264 -vf fps=25 -pix_fmt yuv420p test.mp4`<br> ## Convert mp4 to webm `$ ffmpeg -i example.mp4 -f webm -c:v libvpx -b:v 1M -acodec libvorbis example.webm -hide_banner`<br>
NewerOlder