mirror of
https://github.com/amiaopensource/ffmprovisr.git
synced 2025-02-20 14:09:03 +01:00
commit
9fc38dfe59
59
index.html
59
index.html
@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>ffmprovisr</title>
|
||||
<meta charset="utf-8">
|
||||
@ -17,6 +17,7 @@
|
||||
<script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
|
||||
<div class="text-center">
|
||||
@ -82,26 +83,28 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<p>Part 1: Create 3 second clip from an existing source file (no audio necessary)</p>
|
||||
|
||||
<p>
|
||||
<code>ffmpeg -ss HH:MM:SS -i input.mov -c:v copy -c:a copy -t 3 output.mov</code>
|
||||
<code>ffmpeg -ss HH:MM:SS -i <i>input</i> -c:v copy -c:a copy -t 3 <i>output</i></code>
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>ffmpeg : starts the command</li>
|
||||
<li>-ss HH:MM:SS: The starting point of the gift</li>
|
||||
<li>-t 3: the number of seconds after the starting point repeated in the gif</li>
|
||||
<li><b>ffmpeg</b> starts the command</li>
|
||||
<li><b>-i</b> input file (path, name and extension)</li>
|
||||
<li><b>-ss HH:MM:SS</b> starting point of the gif</li>
|
||||
<li><b>-t 3</b> number of seconds after the starting point repeated in the gif (here 3; can be specified also with a full timestamp, i.e. here 00:00:03)</li>
|
||||
<li>output file (path, name and extension)</li>
|
||||
</ul>
|
||||
|
||||
<p>Part 2: Make the gif</p>
|
||||
|
||||
<p>
|
||||
<code>ffmpeg -i input.mov -vf scale=500:-1 -t 10 -r 30 output.gif</code>
|
||||
<code>ffmpeg -i <i>input</i> -vf scale=500:-1 -t 10 -r 30 <i>output.gif</i></code>
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>ffmpeg : starts the command</li>
|
||||
<li>-vf scale: width:height in pixels (a negative number keeps it in proportion)</li>
|
||||
<li>-t 10: Maximum length of running time</li>
|
||||
<li>-r 30: run at 30 frames per second</li>
|
||||
<li><b>ffmpeg</b> starts the command</li>
|
||||
<li><b>-vf scale=<i>width</i>:<i>height</i></b> in pixels (a negative number keeps it in proportion)</li>
|
||||
<li><b>-t 10</b> running time in seconds (here 10)</li>
|
||||
<li><b>-r 30</b> run at 30 fps (frames per second)</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
@ -130,8 +133,8 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>ffmpeg : starts the command</li>
|
||||
<li>-i for input</li>
|
||||
<li>[inputfile.wav] : file you would like to convert to mp3</li>
|
||||
<li>-sample_fmt s16p: sample format. This will give you 16 bit audio (To see a list of supported sample formats, type: ffmpeg -sample_fmts)</li>
|
||||
<li>-ar 44100: Sets the audio sampling frequency to 44.1 kH (CD quality).</li>
|
||||
<li>-sample_fmt s16p: sample format. This will give you 16 bit audio (To see a list of supported sample formats, type: <code>ffmpeg -sample_fmts</code>)</li>
|
||||
<li>-ar 44100: Sets the audio sampling frequency to 44.1 kHz (CD quality).</li>
|
||||
<li>[outputfile.mp3] : outputname and format</li>
|
||||
</ul>
|
||||
|
||||
@ -189,7 +192,7 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>ffmpeg: starts the command</li>
|
||||
<li>-i for input</li>
|
||||
<li>[inputfile.extension]: the file you want to create framemd5 checksums for</li>
|
||||
<li>-an: ignores the audio track</li>
|
||||
<li>-an: ignores the audio stream (audio no)</li>
|
||||
<li>-f framemed5: file type</li>
|
||||
<li>[outputfile.framemd5]: output name and format</li>
|
||||
</ul>
|
||||
@ -211,7 +214,7 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<h3>Transcode into a deinterlaced Apple ProRes LT</h3>
|
||||
|
||||
<p>
|
||||
<code>ffmpeg -i input.mov -vcodec prores -profile:v 1 -acodec pcm_s16le -vf yadif output.mov</code>
|
||||
<code>ffmpeg -i input.mov -c:v prores -profile:v 1 -c:a pcm_s16le -vf yadif output.mov</code>
|
||||
</p>
|
||||
|
||||
<p>This command transcodes an input file (input.mov) into a deinterlaced Apple ProRes LT .mov file with 16-bit linear PCM encoded audio. The file is deinterlaced using the yadif (Yet Another De-Interlacing Filter) command.</p>
|
||||
@ -220,15 +223,15 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>ffmpeg: Calls the program ffmpeg</li>
|
||||
<li>-i: Tells ffmpeg to expect an input file</li>
|
||||
<li>[inputfile]: Specifies the name and location of the file you want to transcode into ProRes</li>
|
||||
<li>-vcodec prores: Tells ffmpeg to transcode the video stream into Apple ProRes</li>
|
||||
<li>-profile:v 1: Declares profile of Apple ProRes you want to use. The profiles are explained below:</li>
|
||||
<li>-c:v prores: Tells ffmpeg to transcode the video stream into Apple ProRes 422</li>
|
||||
<li>-profile:v 1: Declares profile of ProRes you want to use. The profiles are explained below:
|
||||
<ul>
|
||||
<li>0 : ProRes422 (Proxy)</li>
|
||||
<li>1 : ProRes422 (LT)</li>
|
||||
<li>2 : ProRes422 (Normal)</li>
|
||||
<li>3 : ProRes422 (HQ)</li>
|
||||
</ul>
|
||||
<li>-acodec pcm_s16le: Tells ffmpeg to encode the audio stream in 16-bit Linear PCM</li>
|
||||
</ul></li>
|
||||
<li>-c:a pcm_s16le: Tells ffmpeg to encode the audio stream in 16-bit linear PCM</li>
|
||||
<li>-vf yadif: Runs a deinterlacing video filter (yet another deinterlacing filter) on the new file</li>
|
||||
<li>[output.mov]: Specifies the name, location, and extension of the new ProRes file</li>
|
||||
</ul>
|
||||
@ -349,7 +352,7 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>-show_format: outputs file container</li>
|
||||
<li>-show_streams: outputs audio and video codec</li>
|
||||
<li>-show_data: adds “hexdump” to show_streams command output</li>
|
||||
<li>-print_format: Set the output printing format (in this example “xml”)</li>
|
||||
<li>-print_format: Set the output printing format (in this example “xml”; other formats are “json” and “flat”)</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -377,11 +380,11 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>-f: forces ffmpeg to keep the same file format of the joined files</li>
|
||||
<li>concat: ffmpeg’s concatenate command. This tells ffmpeg to join the files.</li>
|
||||
<li>-i: tells ffmpeg to expect input files</li>
|
||||
<li>mylist.txt: specifies the location of a text file with a list of files to be concatenated. You should create a text file that is formatted as follows:</li>
|
||||
<li>mylist.txt: specifies the location of a text file with a list of files to be concatenated. You should create a text file that is formatted as follows:
|
||||
<ul>
|
||||
<li>file [path to file 1]</li>
|
||||
<li>file [path to file 2]</li>
|
||||
</ul>
|
||||
</ul></li>
|
||||
<li>-c copy: specifies the encoder for the output file by telling ffmpeg to copy the codecs of the original files and use them for the output file</li>
|
||||
<li>[output]: specifies the filename and location for the output file</li>
|
||||
</ul>
|
||||
@ -516,7 +519,7 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<!-- where the text goes -->
|
||||
<div class="well">
|
||||
<h3>Transcode to h.264</h3>
|
||||
<p><code>ffmpeg -i [input file] -vcodec libx264 -acodec copy [output file.mp4]</code></p>
|
||||
<p><code>ffmpeg -i [input file] -c:v libx264 -c:a copy [output file.mp4]</code></p>
|
||||
|
||||
<p>This command takes an input file and transcodes it to h.264 with an .mp4 wrapper, keeping the audio the same codec as the original. The libx264 codec defaults to a “medium” preset for compression quality and a CRF of 23. CRF stands for constant rate factor and determines the quality and file size of the resulting h.264 video. A low CRF means high quality and large file size; a high CRF means the opposite. </p>
|
||||
|
||||
@ -524,21 +527,25 @@ Change the above data-target field, the button text, and the below div class (th
|
||||
<li>ffmpeg: Calls the program ffmpeg</li>
|
||||
<li>-i: Tells ffmpeg to expect an input file</li>
|
||||
<li>[input file]: Tells ffmpeg the location of the file you want to process</li>
|
||||
<li>-vcodec libx264: Tells ffmpeg to change the video codec of the file to h264 -acodec copy: tells ffmpeg not to change the audio codec</li>
|
||||
<li>-c:v libx264: Tells ffmpeg to change the video codec of the file to h264</li>
|
||||
<li>-c:a copy: tells ffmpeg not to change the audio codec</li>
|
||||
<li>[output file.mp4]: Specifies the name and location of the new file, including the desired codec extension</li>
|
||||
</ul>
|
||||
|
||||
<p>In order to use the same basic command to make a higher quality file, you can add some of these presets:</p>
|
||||
<p><code>ffmpeg -i [input file] -vcodec libx264 -acodec copy -preset veryslow -crf 18 [output file.mp4]</code></p>
|
||||
|
||||
<ul>
|
||||
<li>-preset veryslow: This option tells ffmpeg to use the slowest preset possible for the best compression quality</li>
|
||||
<li>-crf 18: Specifying a lower CRF will make a larger file with better visual quality</li>
|
||||
</ul>
|
||||
|
||||
<p>libx264 also defaults to 4:2:2 chroma subsampling. Some versions of Quicktime can't read x264 files in 4:2:2. In order to allow the video to play in all Quicktime players, you can specify 4:2:0 chroma subsampling instead:</p>
|
||||
<p><code>ffmpeg -i [input file] -vcodec libx264 -pix_fmt yuv420p -acodec copy -preset veryslow -crf 18 [output file.mp4]</code></p>
|
||||
<p><code>ffmpeg -i [input file] -c:v libx264 -pix_fmt yuv420p -c:a copy -preset veryslow -crf 18 [output file.mp4]</code></p>
|
||||
|
||||
<ul>
|
||||
<li>-pix_fmt yuv420p: Specifies a pixel format of YUV 4:2:0 to allow the file to play in a standard Quicktime player</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -646,5 +653,7 @@ outputfile.mpg: Specifies the name and location of your output file </li>
|
||||
<div class="footer text-center">
|
||||
<p>Made with ♥ at <a href="http://wiki.curatecamp.org/index.php/Association_of_Moving_Image_Archivists_%26_Digital_Library_Federation_Hack_Day_2015">AMIA #AVhack15</a>! Contribute to the project via <a href="https://github.com/amiaopensource/ffmprovisr">our Github page</a>!</p>
|
||||
</div>
|
||||
|
||||
</div> <!-- class="container" -->
|
||||
</body>
|
||||
</html>
|
||||
|
Loading…
x
Reference in New Issue
Block a user