source: multimedia/videoutils/ffmpeg.xml@ 3d1f2a6

10.0 10.1 11.0 11.1 7.10 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 krejzi/svn lazarus nosym perl-modules qt5new systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/test-20220226
Last change on this file since 3d1f2a6 was 3d1f2a6, checked in by Fernando de Oliveira <fernando@…>, 8 years ago

Typo FFmpeg-2.1.1.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@12511 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 21.4 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY ffmpeg-download-http
8 "http://ffmpeg.org/releases/ffmpeg-&ffmpeg-version;.tar.bz2">
9 <!ENTITY ffmpeg-download-ftp " ">
10 <!ENTITY ffmpeg-md5sum "2719ab2b3311ac3775b9cdeb66c54849">
11 <!ENTITY ffmpeg-size "6.4 MB">
12 <!ENTITY ffmpeg-buildsize "114 MB (additional 710 MB for docs and 1.5 GB
13 for tests)">
14 <!ENTITY ffmpeg-time "3.1 SBU (additional 0.6 SBU for docs 12.3 to
15 run the tests, after test files are downloaded)">
16]>
17
18<sect1 id="ffmpeg" xreflabel="FFmpeg-&ffmpeg-version;">
19 <?dbhtml filename="ffmpeg.html"?>
20
21 <sect1info>
22 <othername>$LastChangedBy$</othername>
23 <date>$Date$</date>
24 </sect1info>
25
26 <title>FFmpeg-&ffmpeg-version;</title>
27
28 <indexterm zone="ffmpeg">
29 <primary sortas="a-FFmpeg">FFmpeg</primary>
30 </indexterm>
31
32 <sect2 role="package">
33 <title>Introduction to FFmpeg</title>
34
35 <para>
36 <application>FFmpeg</application> is a solution to record, convert and
37 stream audio and video. It is a very fast video and audio converter and it
38 can also acquire from a live audio/video source. Designed to be intuitive,
39 the command-line interface (<command>ffmpeg</command>) tries to figure out
40 all the parameters, when possible. <application>FFmpeg</application> can
41 also convert from any sample rate to any other, and resize video on the
42 fly with a high quality polyphase filter.
43 <application>FFmpeg</application> can use a Video4Linux compatible video
44 source and any Open Sound System audio source.
45 </para>
46
47 &lfs74_checked;
48
49 <bridgehead renderas="sect3">Package Information</bridgehead>
50 <itemizedlist spacing="compact">
51 <listitem>
52 <para>
53 Download (HTTP): <ulink url="&ffmpeg-download-http;"/>
54 </para>
55 </listitem>
56 <listitem>
57 <para>
58 Download (FTP): <ulink url="&ffmpeg-download-ftp;"/>
59 </para>
60 </listitem>
61 <listitem>
62 <para>
63 Download MD5 sum: &ffmpeg-md5sum;
64 </para>
65 </listitem>
66 <listitem>
67 <para>
68 Download size: &ffmpeg-size;
69 </para>
70 </listitem>
71 <listitem>
72 <para>
73 Estimated disk space required: &ffmpeg-buildsize;
74 </para>
75 </listitem>
76 <listitem>
77 <para>
78 Estimated build time: &ffmpeg-time;
79 </para>
80 </listitem>
81 </itemizedlist>
82
83 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
84 <itemizedlist spacing="compact">
85 <listitem>
86 <para>
87 Required patch (in case you build with freetype support):
88 <ulink url="&patch-root;/ffmpeg-&ffmpeg-version;-freetype-1.patch"/>
89 </para>
90 </listitem>
91 </itemizedlist>
92
93 <bridgehead renderas="sect3">FFmpeg Dependencies</bridgehead>
94
95 <bridgehead renderas="sect4">Recommended</bridgehead>
96 <para role="recommended">
97 <xref linkend="yasm"/>,
98 <xref linkend="libass"/>,
99 <xref linkend="fdk-aac"/>,
100 <xref linkend="lame"/>,
101 <xref linkend="opus"/>,
102 <xref linkend="libtheora"/>,
103 <xref linkend="libvorbis"/>,
104 <xref linkend="libvpx"/>, and
105 <xref linkend="x264"/>
106 </para>
107
108 <bridgehead renderas="sect4">Recommended for desktop use</bridgehead>
109 <para>
110 <xref linkend="x-window-system"/>,
111 <xref linkend="alsa-lib"/>,
112 <xref linkend="sdl"/>,
113 <xref linkend="libva"/> and
114 <xref linkend="libvdpau"/> (with the corresponding driver package)
115 </para>
116
117 <bridgehead renderas="sect4">Optional</bridgehead>
118 <para role="optional">
119 <xref linkend="faac"/>,
120 <xref linkend="freetype2"/>,
121 <xref linkend="openjpeg"/>,
122 <xref linkend="pulseaudio"/>,
123 <xref linkend="speex"/>,
124 <xref linkend="xvid"/>,
125 <xref linkend="openssl"/>,
126 <xref linkend="fontconfig"/>,
127 <ulink url="http://www.piksel.org/frei0r">frei0r</ulink>,
128 <xref linkend="gnutls"/>,
129 <ulink url="http://www.ladspa.org/">LADSPA</ulink>,
130 <ulink url="http://www.libssh.org/">libssh</ulink>,
131 <ulink url="http://zapping.sourceforge.net/ZVBI/">ZVBI</ulink>,
132 <ulink url="http://tipok.org.ua/node/17">libaacplus</ulink>,
133 <ulink url="http://www.videolan.org/developers/libbluray.html">libbluray</ulink>,
134 <ulink url="http://caca.zoy.org/">libcaca</ulink>,
135 <ulink url="http://www.celt-codec.org/">libcelt</ulink>,
136 <ulink url="http://ftp.gnu.org/pub/gnu/libcdio/">libcdio</ulink>,
137 <ulink url="http://sourceforge.net/projects/libdc1394">libdc1394</ulink>,
138 <ulink url="http://www.speech.cs.cmu.edu/flite/">Flite</ulink>,
139 <ulink url="http://www.quut.com/gsm/">GSM</ulink>,
140 <ulink url="https://ieee1394.wiki.kernel.org/index.php/Libraries">libiec61883</ulink>,
141 <ulink url="https://github.com/dekkers/libilbc">libilbc</ulink>,
142 <ulink url="http://sourceforge.net/projects/modplug-xmms/">libmodplug</ulink>,
143 <ulink url="https://github.com/Distrotech/libnut">libnut</ulink> (Git checkout),
144 <ulink url="http://sourceforge.net/projects/opencore-amr">OpenCore AMR</ulink>,
145 <ulink url="http://opencv.org/">OpenCV</ulink>,
146 <ulink url="http://rtmpdump.mplayerhq.hu/">librtmp</ulink>,
147 <ulink url="http://diracvideo.org/">Schroedinger</ulink>,
148 <ulink url="http://www.twolame.org/">TwoLAME</ulink>,
149 <ulink url="http://linuxtv.org/downloads/v4l-utils/">Video4Linux</ulink>,
150 <ulink url="http://sourceforge.net/projects/opencore-amr/files/vo-aacenc/">vo-aaenc</ulink>,
151 <ulink url="http://sourceforge.net/projects/opencore-amr/files/vo-amrwbenc/">vo-amrwbenc</ulink>,
152 <ulink url="http://xavs.sourceforge.net/">libxavs</ulink> (SVN checkout),
153 <ulink url="http://kcat.strangesoft.net/openal-releases/">OpenAL</ulink>, and
154 <ulink url="http://www.nongnu.org/texi2html">texi2html</ulink> (to build HTML documentation)
155 </para>
156
157 <para condition="html" role="usernotes">
158 User Notes: <ulink url="&blfs-wiki;/ffmpeg"/>
159 </para>
160 </sect2>
161
162 <sect2 role="installation">
163 <title>Installation of FFmpeg</title>
164
165<!--<para>
166 If <application>Xorg</application> is installed in a prefix other
167 than <filename class='directory'>/usr</filename>, the build will fail. Fix
168 this by issuing the following command:
169 </para>
170
171<screen><userinput>export LIBRARY_PATH=$XORG_PREFIX/lib</userinput></screen>
172-->
173 <para>
174 In case you are building with freetype support (see "Command
175 Explanations", below), apply this patch:
176 </para>
177
178<screen><userinput>patch -Np1 -i ../ffmpeg-&ffmpeg-version;-freetype-1.patch</userinput></screen>
179
180 <para>
181 Install <application>FFmpeg</application> by running the following
182 commands:
183 </para>
184
185<screen><userinput>sed -i 's/-lflite"/-lflite -lasound"/' configure &amp;&amp;
186./configure --prefix=/usr \
187 --enable-gpl \
188 --enable-version3 \
189 --enable-nonfree \
190 --disable-static \
191 --enable-shared \
192 --disable-debug \
193 --enable-libass \
194 --enable-libfdk-aac \
195 --enable-libmp3lame \
196 --enable-libopus \
197 --enable-libtheora \
198 --enable-libvorbis \
199 --enable-libvpx \
200 --enable-libx264 \
201 --enable-x11grab &amp;&amp;
202make &amp;&amp;
203gcc tools/qt-faststart.c -o tools/qt-faststart &amp;&amp;
204unset LIBRARY_PATH</userinput></screen>
205
206 <para>
207 HTML documentation was built in the previous step if
208 <ulink url="http://www.nongnu.org/texi2html">texi2html</ulink> is
209 installed. If the HTML was built (check for any
210 <filename class="extension">.html</filename> files in the
211 <filename class="directory">doc</filename> directory) and you have
212 <xref linkend="texlive"/> installed and wish to build PDF and
213 Postscript versions of the documentation, issue the following commands:
214 </para>
215
216<screen><userinput>pushd doc &amp;&amp;
217for DOCNAME in `basename -s .html *.html`
218do
219 texi2pdf -b $DOCNAME.texi &amp;&amp;
220 texi2dvi -b $DOCNAME.texi &amp;&amp;
221 dvips -o $DOCNAME.ps \
222 $DOCNAME.dvi
223done &amp;&amp;
224popd &amp;&amp;
225unset DOCNAME</userinput></screen>
226
227 <para>
228 If you have <xref linkend="doxygen"/> installed and wish to create the API
229 documentation (takes about 350 MB of space), issue the command
230 <command>doxygen doc/Doxyfile</command>.
231 </para>
232
233 <para>
234 To properly test the installation you must have <xref linkend="rsync"/>
235 installed and follow the instructions for the
236 <ulink url="http://ffmpeg.org/FATE.html">
237 FFmpeg Automated Testing Environment</ulink> (FATE). First, about 736 MB
238 of data files used to run FATE are downloaded. Next, FATE is executed.
239 Estimated values in "Package Information" do not include the download SBU.
240 </para>
241
242 <para>
243 Now, as the <systemitem class="username">root</systemitem> user:
244 </para>
245
246<screen role="root"><userinput>make install &amp;&amp;
247install -v -m755 tools/qt-faststart /usr/bin &amp;&amp;
248install -v -m755 -d /usr/share/doc/ffmpeg &amp;&amp;
249install -v -m644 doc/*.txt \
250 /usr/share/doc/ffmpeg</userinput></screen>
251
252 <para>
253 If HTML documentation was built, issue the following command to install it:
254 </para>
255
256<screen role="root"><userinput>install -v -m644 doc/*.html \
257 /usr/share/doc/ffmpeg</userinput></screen>
258
259 <para>
260 If you used <command>doxygen</command> to create the API documentation,
261 install it (another 300 MB of space) by issuing the following commands
262 as the <systemitem class="username">root</systemitem> user:
263 </para>
264
265<screen role="root"><userinput>install -v -m755 -d /usr/share/doc/ffmpeg/api &amp;&amp;
266install -v -m644 doc/doxy/html/* \
267 /usr/share/doc/ffmpeg/api</userinput></screen>
268
269 </sect2>
270
271 <sect2 role="commands">
272 <title>Command Explanations</title>
273
274 <para>
275 <command>sed -i ...</command>: This command adds the
276 <application>ALSA</application> library to the
277 <application>Flite</application> <envar>LDFLAGS</envar> variable and
278 enables the discovery of <application>Flite</application>.
279 </para>
280
281 <para>
282 <option>--enable-libfreetype</option>: Enables
283 <application>Freetype</application> support.
284 </para>
285
286 <para>
287 <parameter>--enable-gpl</parameter>: Enables the use of GPL code and
288 permits support for postprocessing, swscale and many other features.
289 </para>
290
291 <para>
292 <parameter>--enable-version3</parameter>: Enables the use of (L)GPL
293 version 3 code.
294 </para>
295
296 <para>
297 <parameter>--enable-nonfree</parameter>: Enables the use of nonfree
298 code. Note that the resulting libraries and binaries will be
299 unredistributable.
300 </para>
301
302 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
303 href="../../xincludes/static-libraries.xml"/>
304
305 <para>
306 <parameter>--enable-shared</parameter>: Enables building shared libraries,
307 otherwise only static libraries are built and installed.
308 </para>
309
310 <para>
311 <parameter>--disable-debug</parameter>: Disables building debugging
312 symbols into the programs and libraries.
313 </para>
314
315 <para>
316 <parameter>--enable-libass</parameter>: Enables ASS/SSA subtitle format
317 rendering via <filename class="libraryfile">libass</filename>.
318 </para>
319
320 <para>
321 <parameter>--enable-libfdk-aac</parameter>: Enables currently the
322 highest-quality AAC audio encoding via <filename
323 class="libraryfile">libfdk-aac</filename>.
324 </para>
325
326 <para>
327 <parameter>--enable-libmp3lame</parameter>: Enables MP3 audio encoding via
328 <filename class="libraryfile">libmp3lame</filename>.
329 </para>
330
331 <para>
332 <parameter>--enable-libopus</parameter>: Enables Opus encoding for low
333 latency streaming via <filename class="libraryfile">libopus</filename>.
334 </para>
335
336 <para>
337 <parameter>--enable-libvorbis --enable-libtheora</parameter>: Enables
338 Theora video encoding via <filename
339 class="libraryfile">libvorbis</filename> and <filename
340 class="libraryfile">libtheora</filename>.
341 </para>
342
343 <para>
344 <parameter>--enable-libvorbis --enable-libvpx</parameter>: Enables WebM
345 encoding via <filename class="libraryfile">libvorbis</filename> and
346 <filename class="libraryfile">libvpx</filename>.
347 </para>
348
349 <para>
350 <parameter>--enable-libx264</parameter>: Enables high-quality H.264/MPEG-4
351 AVC encoding via <filename class="libraryfile">libx264</filename>.
352 </para>
353
354 <para>
355 <parameter>--enable-x11grab</parameter>: Enables X11 grabbing.
356 </para>
357
358 <para>
359 <command>gcc tools/qt-faststart.c -o tools/qt-faststart</command>:
360 This builds the <command>qt-faststart</command> program which can
361 modify QuickTime formatted movies
362 (<filename class="extension">.mov</filename> or
363 <filename class="extension">.mp4</filename>) so that the header information
364 is located at the beginning of the file instead of the end. This allows
365 the movie file to begin playing before the entire file has been downloaded.
366 </para>
367
368 <note>
369 <para>
370 Support for most of the dependency packages requires using options
371 passed to the <command>configure</command> script. View the output
372 from <command>./configure --help</command> for complete information
373 about enabling dependency packages.
374 </para>
375 </note>
376
377 </sect2>
378
379 <sect2 role="configuration">
380 <title>Configuring FFmpeg</title>
381
382 <sect3 id="ffmpeg-config">
383 <title>Config Files</title>
384
385 <para>
386 <filename>/etc/ffserver.conf</filename> and
387 <filename>~/.ffmpeg/ffserver-config</filename>
388 </para>
389
390 <indexterm zone="ffmpeg ffmpeg-config">
391 <primary
392 sortas="e-AA.ffmpeg-ffserver-config">~/.ffmpeg/ffserver-config</primary>
393 </indexterm>
394
395 <indexterm zone="ffmpeg ffmpeg-config">
396 <primary sortas="e-etc-ffserver.conf">/etc/ffserver.conf</primary>
397 </indexterm>
398
399 <para>
400 You'll find a sample <command>ffserver</command> configuration file at
401 <filename>doc/ffserver.conf</filename> in the source tree.
402 </para>
403
404 </sect3>
405
406 </sect2>
407
408 <sect2 role="content">
409 <title>Contents</title>
410
411 <segmentedlist>
412 <segtitle>Installed Programs</segtitle>
413 <segtitle>Installed Libraries</segtitle>
414 <segtitle>Installed Directories</segtitle>
415
416 <seglistitem>
417 <seg>
418 ffmpeg, ffplay, ffprobe, ffserver, and
419 qt-faststart
420 </seg>
421 <seg>
422 libavcodec.so, libavdevice.so, libavfilter.so,
423 libavformat.so, libavutil.so, libpostproc.so,
424 libswresample, and libswscale.so
425 </seg>
426 <seg>
427 /usr/include/libavcodec,
428 /usr/include/libavdevice,
429 /usr/include/libavfilter,
430 /usr/include/libavformat,
431 /usr/include/libavutil,
432 /usr/include/libpostproc,
433 /usr/include/libswresample
434 /usr/include/libswscale,
435 /usr/share/ffmpeg, and
436 /usr/share/doc/ffmpeg
437 </seg>
438 </seglistitem>
439 </segmentedlist>
440
441 <variablelist>
442 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
443 <?dbfo list-presentation="list"?>
444 <?dbhtml list-presentation="table"?>
445
446 <varlistentry id="ffmpeg-prog">
447 <term><command>ffmpeg</command></term>
448 <listitem>
449 <para>
450 is a command-line tool to convert video files, network streams and
451 input from a TV card to several video formats.
452 </para>
453 <indexterm zone="ffmpeg ffmpeg-prog">
454 <primary sortas="b-ffmpeg">ffmpeg</primary>
455 </indexterm>
456 </listitem>
457 </varlistentry>
458
459 <varlistentry id="ffplay">
460 <term><command>ffplay</command></term>
461 <listitem>
462 <para>
463 is a very simple and portable media player using the
464 <filename>ffmpeg</filename> libraries and the SDL library.
465 </para>
466 <indexterm zone="ffmpeg ffplay">
467 <primary sortas="b-ffplay">ffplay</primary>
468 </indexterm>
469 </listitem>
470 </varlistentry>
471
472 <varlistentry id="ffprobe">
473 <term><command>ffprobe</command></term>
474 <listitem>
475 <para>
476 gathers information from multimedia streams and prints it in a human
477 and machine-readable fashion.
478 </para>
479 <indexterm zone="ffmpeg ffprobe">
480 <primary sortas="b-ffprobe">ffprobe</primary>
481 </indexterm>
482 </listitem>
483 </varlistentry>
484
485 <varlistentry id="ffserver">
486 <term><command>ffserver</command></term>
487 <listitem>
488 <para>
489 is a streaming server for everything that <command>ffmpeg</command>
490 could use as input (files, streams, TV card input, webcam, etc).
491 </para>
492 <indexterm zone="ffmpeg ffserver">
493 <primary sortas="b-ffserver">ffserver</primary>
494 </indexterm>
495 </listitem>
496 </varlistentry>
497
498 <varlistentry id="qt-faststart">
499 <term><command>qt-faststart</command></term>
500 <listitem>
501 <para>
502 moves the index file to the front of quicktime (mov/mp4) videos.
503 </para>
504 <indexterm zone="ffmpeg qt-faststart">
505 <primary sortas="b-qt-faststart">qt-faststart</primary>
506 </indexterm>
507 </listitem>
508 </varlistentry>
509
510 <varlistentry id="libavcodec">
511 <term><filename class="libraryfile">libavcodec.so</filename></term>
512 <listitem>
513 <para>
514 is a library containing the <application>FFmpeg</application> codecs
515 (both encoding and decoding).
516 </para>
517 <indexterm zone="ffmpeg libavcodec">
518 <primary sortas="c-libavcodec">libavcodec.so</primary>
519 </indexterm>
520 </listitem>
521 </varlistentry>
522
523 <varlistentry id="libavdevice">
524 <term><filename class="libraryfile">libavdevice.so</filename></term>
525 <listitem>
526 <para>
527 is the <application>FFmpeg</application> device handling library.
528 </para>
529 <indexterm zone="ffmpeg libavdevice">
530 <primary sortas="c-libavdevice">libavdevice.so</primary>
531 </indexterm>
532 </listitem>
533 </varlistentry>
534
535 <varlistentry id="libavfilter">
536 <term><filename class="libraryfile">libavfilter.so</filename></term>
537 <listitem>
538 <para>
539 is a library of filters that can alter video or audio between the
540 decoder and the encoder (or output).
541 </para>
542 <indexterm zone="ffmpeg libavfilter">
543 <primary sortas="c-libavfilter">libavfilter.so</primary>
544 </indexterm>
545 </listitem>
546 </varlistentry>
547
548 <varlistentry id="libavformat">
549 <term><filename class="libraryfile">libavformat.so</filename></term>
550 <listitem>
551 <para>
552 is a library containing the file formats handling (mux and demux
553 code for several formats) used by <command>ffplay</command> as well
554 as allowing the generation of audio or video streams.
555 </para>
556 <indexterm zone="ffmpeg libavformat">
557 <primary sortas="c-libavformat">libavformat.so</primary>
558 </indexterm>
559 </listitem>
560 </varlistentry>
561
562 <varlistentry id="libavutil">
563 <term><filename class="libraryfile">libavutil.so</filename></term>
564 <listitem>
565 <para>
566 is the <application>FFmpeg</application> utility library.
567 </para>
568 <indexterm zone="ffmpeg libavutil">
569 <primary sortas="c-libavutil">libavutil.so</primary>
570 </indexterm>
571 </listitem>
572 </varlistentry>
573
574 <varlistentry id="libpostproc">
575 <term><filename class="libraryfile">libpostproc.so</filename></term>
576 <listitem>
577 <para>
578 is the <application>FFmpeg</application> post processing library.
579 </para>
580 <indexterm zone="ffmpeg libpostproc">
581 <primary sortas="c-libpostproc">libpostproc.so</primary>
582 </indexterm>
583 </listitem>
584 </varlistentry>
585
586 <varlistentry id="libswresample">
587 <term><filename class="libraryfile">libswresample.so</filename></term>
588 <listitem>
589 <para>
590 is the <application>FFmpeg</application> audio rescaling library,
591 it contains functions for converting audio sample formats.
592 </para>
593 <indexterm zone="ffmpeg libswresample">
594 <primary sortas="c-libswresample">libswresample.so</primary>
595 </indexterm>
596 </listitem>
597 </varlistentry>
598
599 <varlistentry id="libswscale">
600 <term><filename class="libraryfile">libswscale.so</filename></term>
601 <listitem>
602 <para>
603 is the <application>FFmpeg</application> image rescaling library.
604 </para>
605 <indexterm zone="ffmpeg libswscale">
606 <primary sortas="c-libswscale">libswscale.so</primary>
607 </indexterm>
608 </listitem>
609 </varlistentry>
610
611 </variablelist>
612
613 </sect2>
614
615</sect1>
Note: See TracBrowser for help on using the repository browser.