1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html401/loose.dtd">
3 <!-- Created on September 2, 2011 by texi2html 1.82
4 texi2html was written by:
5 Lionel Cons <Lionel.Cons@cern.ch> (original author)
6 Karl Berry <karl@freefriends.org>
7 Olaf Bachmann <obachman@mathematik.uni-kl.de>
9 Maintained by: Many creative people.
10 Send bugs and suggestions to <texi2html-bug@nongnu.org>
13 <title>FFmpeg FAQ</title>
15 <meta name="description" content="FFmpeg FAQ">
16 <meta name="keywords" content="FFmpeg FAQ">
17 <meta name="resource-type" content="document">
18 <meta name="distribution" content="global">
19 <meta name="Generator" content="texi2html 1.82">
20 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
21 <style type="text/css">
23 a.summary-letter {text-decoration: none}
24 blockquote.smallquotation {font-size: smaller}
25 pre.display {font-family: serif}
26 pre.format {font-family: serif}
27 pre.menu-comment {font-family: serif}
28 pre.menu-preformatted {font-family: serif}
29 pre.smalldisplay {font-family: serif; font-size: smaller}
30 pre.smallexample {font-size: smaller}
31 pre.smallformat {font-family: serif; font-size: smaller}
32 pre.smalllisp {font-size: smaller}
33 span.roman {font-family:serif; font-weight:normal;}
34 span.sansserif {font-family:sans-serif; font-weight:normal;}
35 ul.toc {list-style: none}
42 <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
44 <a name="SEC_Top"></a>
45 <h1 class="settitle">FFmpeg FAQ</h1>
47 <a name="SEC_Contents"></a>
48 <h1>Table of Contents</h1>
49 <div class="contents">
52 <li><a name="toc-General-Questions" href="#General-Questions">1. General Questions</a>
54 <li><a name="toc-When-will-the-next-FFmpeg-version-be-released_003f-_002f-Why-are-FFmpeg-releases-so-few-and-far-between_003f" href="#When-will-the-next-FFmpeg-version-be-released_003f-_002f-Why-are-FFmpeg-releases-so-few-and-far-between_003f">1.1 When will the next FFmpeg version be released? / Why are FFmpeg releases so few and far between?</a></li>
55 <li><a name="toc-I-have-a-problem-with-an-old-version-of-FFmpeg_003b-where-should-I-report-it_003f" href="#I-have-a-problem-with-an-old-version-of-FFmpeg_003b-where-should-I-report-it_003f">1.2 I have a problem with an old version of FFmpeg; where should I report it?</a></li>
56 <li><a name="toc-Why-doesn_0027t-FFmpeg-support-feature-_005bxyz_005d_003f" href="#Why-doesn_0027t-FFmpeg-support-feature-_005bxyz_005d_003f">1.3 Why doesn’t FFmpeg support feature [xyz]?</a></li>
57 <li><a name="toc-FFmpeg-does-not-support-codec-XXX_002e-Can-you-include-a-Windows-DLL-loader-to-support-it_003f" href="#FFmpeg-does-not-support-codec-XXX_002e-Can-you-include-a-Windows-DLL-loader-to-support-it_003f">1.4 FFmpeg does not support codec XXX. Can you include a Windows DLL loader to support it?</a></li>
58 <li><a name="toc-My-bug-report_002fmail-to-ffmpeg_002ddevel_002fuser-has-not-received-any-replies_002e" href="#My-bug-report_002fmail-to-ffmpeg_002ddevel_002fuser-has-not-received-any-replies_002e">1.5 My bug report/mail to ffmpeg-devel/user has not received any replies.</a></li>
59 <li><a name="toc-Is-there-a-forum-for-FFmpeg_003f-I-do-not-like-mailing-lists_002e" href="#Is-there-a-forum-for-FFmpeg_003f-I-do-not-like-mailing-lists_002e">1.6 Is there a forum for FFmpeg? I do not like mailing lists.</a></li>
60 <li><a name="toc-I-cannot-read-this-file-although-this-format-seems-to-be-supported-by-ffmpeg_002e" href="#I-cannot-read-this-file-although-this-format-seems-to-be-supported-by-ffmpeg_002e">1.7 I cannot read this file although this format seems to be supported by ffmpeg.</a></li>
61 <li><a name="toc-Which-codecs-are-supported-by-Windows_003f" href="#Which-codecs-are-supported-by-Windows_003f">1.8 Which codecs are supported by Windows?</a></li>
63 <li><a name="toc-Compilation" href="#Compilation">2. Compilation</a>
65 <li><a name="toc-error_003a-can_0027t-find-a-register-in-class-_0027GENERAL_005fREGS_0027-while-reloading-_0027asm_0027" href="#error_003a-can_0027t-find-a-register-in-class-_0027GENERAL_005fREGS_0027-while-reloading-_0027asm_0027">2.1 <code>error: can't find a register in class 'GENERAL_REGS' while reloading 'asm'</code></a></li>
67 <li><a name="toc-Usage" href="#Usage">3. Usage</a>
69 <li><a name="toc-ffmpeg-does-not-work_003b-what-is-wrong_003f" href="#ffmpeg-does-not-work_003b-what-is-wrong_003f">3.1 ffmpeg does not work; what is wrong?</a></li>
70 <li><a name="toc-How-do-I-encode-single-pictures-into-movies_003f" href="#How-do-I-encode-single-pictures-into-movies_003f">3.2 How do I encode single pictures into movies?</a></li>
71 <li><a name="toc-How-do-I-encode-movie-to-single-pictures_003f" href="#How-do-I-encode-movie-to-single-pictures_003f">3.3 How do I encode movie to single pictures?</a></li>
72 <li><a name="toc-Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f" href="#Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f">3.4 Why do I see a slight quality degradation with multithreaded MPEG* encoding?</a></li>
73 <li><a name="toc-How-can-I-read-from-the-standard-input-or-write-to-the-standard-output_003f" href="#How-can-I-read-from-the-standard-input-or-write-to-the-standard-output_003f">3.5 How can I read from the standard input or write to the standard output?</a></li>
74 <li><a name="toc-_002df-jpeg-doesn_0027t-work_002e" href="#g_t_002df-jpeg-doesn_0027t-work_002e">3.6 -f jpeg doesn’t work.</a></li>
75 <li><a name="toc-Why-can-I-not-change-the-framerate_003f" href="#Why-can-I-not-change-the-framerate_003f">3.7 Why can I not change the framerate?</a></li>
76 <li><a name="toc-How-do-I-encode-Xvid-or-DivX-video-with-ffmpeg_003f" href="#How-do-I-encode-Xvid-or-DivX-video-with-ffmpeg_003f">3.8 How do I encode Xvid or DivX video with ffmpeg?</a></li>
77 <li><a name="toc-How-do-I-encode-videos-which-play-on-the-iPod_003f" href="#How-do-I-encode-videos-which-play-on-the-iPod_003f">3.9 How do I encode videos which play on the iPod?</a></li>
78 <li><a name="toc-How-do-I-encode-videos-which-play-on-the-PSP_003f" href="#How-do-I-encode-videos-which-play-on-the-PSP_003f">3.10 How do I encode videos which play on the PSP?</a></li>
79 <li><a name="toc-Which-are-good-parameters-for-encoding-high-quality-MPEG_002d4_003f" href="#Which-are-good-parameters-for-encoding-high-quality-MPEG_002d4_003f">3.11 Which are good parameters for encoding high quality MPEG-4?</a></li>
80 <li><a name="toc-Which-are-good-parameters-for-encoding-high-quality-MPEG_002d1_002fMPEG_002d2_003f" href="#Which-are-good-parameters-for-encoding-high-quality-MPEG_002d1_002fMPEG_002d2_003f">3.12 Which are good parameters for encoding high quality MPEG-1/MPEG-2?</a></li>
81 <li><a name="toc-Interlaced-video-looks-very-bad-when-encoded-with-ffmpeg_002c-what-is-wrong_003f" href="#Interlaced-video-looks-very-bad-when-encoded-with-ffmpeg_002c-what-is-wrong_003f">3.13 Interlaced video looks very bad when encoded with ffmpeg, what is wrong?</a></li>
82 <li><a name="toc-How-can-I-read-DirectShow-files_003f" href="#How-can-I-read-DirectShow-files_003f">3.14 How can I read DirectShow files?</a></li>
83 <li><a name="toc-How-can-I-join-video-files_003f" href="#How-can-I-join-video-files_003f">3.15 How can I join video files?</a></li>
84 <li><a name="toc-The-ffmpeg-program-does-not-respect-the-_002dmaxrate-setting_002c-some-frames-are-bigger-than-maxrate_002ffps_002e" href="#The-ffmpeg-program-does-not-respect-the-_002dmaxrate-setting_002c-some-frames-are-bigger-than-maxrate_002ffps_002e">3.16 The ffmpeg program does not respect the -maxrate setting, some frames are bigger than maxrate/fps.</a></li>
85 <li><a name="toc-I-want-CBR_002c-but-no-matter-what-I-do-frame-sizes-differ_002e" href="#I-want-CBR_002c-but-no-matter-what-I-do-frame-sizes-differ_002e">3.17 I want CBR, but no matter what I do frame sizes differ.</a></li>
86 <li><a name="toc-How-do-I-check-if-a-stream-is-CBR_003f" href="#How-do-I-check-if-a-stream-is-CBR_003f">3.18 How do I check if a stream is CBR?</a></li>
88 <li><a name="toc-Development" href="#Development">4. Development</a>
90 <li><a name="toc-Are-there-examples-illustrating-how-to-use-the-FFmpeg-libraries_002c-particularly-libavcodec-and-libavformat_003f" href="#Are-there-examples-illustrating-how-to-use-the-FFmpeg-libraries_002c-particularly-libavcodec-and-libavformat_003f">4.1 Are there examples illustrating how to use the FFmpeg libraries, particularly libavcodec and libavformat?</a></li>
91 <li><a name="toc-Can-you-support-my-C-compiler-XXX_003f" href="#Can-you-support-my-C-compiler-XXX_003f">4.2 Can you support my C compiler XXX?</a></li>
92 <li><a name="toc-Is-Microsoft-Visual-C_002b_002b-supported_003f" href="#Is-Microsoft-Visual-C_002b_002b-supported_003f">4.3 Is Microsoft Visual C++ supported?</a></li>
93 <li><a name="toc-Can-I-use-FFmpeg-or-libavcodec-under-Windows_003f" href="#Can-I-use-FFmpeg-or-libavcodec-under-Windows_003f">4.4 Can I use FFmpeg or libavcodec under Windows?</a></li>
94 <li><a name="toc-Can-you-add-automake_002c-libtool-or-autoconf-support_003f" href="#Can-you-add-automake_002c-libtool-or-autoconf-support_003f">4.5 Can you add automake, libtool or autoconf support?</a></li>
95 <li><a name="toc-Why-not-rewrite-ffmpeg-in-object_002doriented-C_002b_002b_003f" href="#Why-not-rewrite-ffmpeg-in-object_002doriented-C_002b_002b_003f">4.6 Why not rewrite ffmpeg in object-oriented C++?</a></li>
96 <li><a name="toc-Why-are-the-ffmpeg-programs-devoid-of-debugging-symbols_003f" href="#Why-are-the-ffmpeg-programs-devoid-of-debugging-symbols_003f">4.7 Why are the ffmpeg programs devoid of debugging symbols?</a></li>
97 <li><a name="toc-I-do-not-like-the-LGPL_002c-can-I-contribute-code-under-the-GPL-instead_003f" href="#I-do-not-like-the-LGPL_002c-can-I-contribute-code-under-the-GPL-instead_003f">4.8 I do not like the LGPL, can I contribute code under the GPL instead?</a></li>
98 <li><a name="toc-I-want-to-compile-xyz_002ec-alone-but-my-compiler-produced-many-errors_002e" href="#I-want-to-compile-xyz_002ec-alone-but-my-compiler-produced-many-errors_002e">4.9 I want to compile xyz.c alone but my compiler produced many errors.</a></li>
99 <li><a name="toc-I_0027m-using-libavcodec-from-within-my-C_002b_002b-application-but-the-linker-complains-about-missing-symbols-which-seem-to-be-available_002e" href="#I_0027m-using-libavcodec-from-within-my-C_002b_002b-application-but-the-linker-complains-about-missing-symbols-which-seem-to-be-available_002e">4.10 I’m using libavcodec from within my C++ application but the linker complains about missing symbols which seem to be available.</a></li>
100 <li><a name="toc-I-have-a-file-in-memory-_002f-a-API-different-from-_002aopen_002f_002aread_002f-libc-how-do-I-use-it-with-libavformat_003f" href="#I-have-a-file-in-memory-_002f-a-API-different-from-_002aopen_002f_002aread_002f-libc-how-do-I-use-it-with-libavformat_003f">4.11 I have a file in memory / a API different from *open/*read/ libc how do I use it with libavformat?</a></li>
101 <li><a name="toc-I-get-_0022No-compatible-shell-script-interpreter-found_002e_0022-in-MSys_002e" href="#I-get-_0022No-compatible-shell-script-interpreter-found_002e_0022-in-MSys_002e">4.12 I get "No compatible shell script interpreter found." in MSys.</a></li>
102 <li><a name="toc-I-get-_0022_002e_002fconfigure_003a-line-_003cxxx_003e_003a-pr_003a-command-not-found_0022-in-MSys_002e" href="#I-get-_0022_002e_002fconfigure_003a-line-_003cxxx_003e_003a-pr_003a-command-not-found_0022-in-MSys_002e">4.13 I get "./configure: line <xxx>: pr: command not found" in MSys.</a></li>
103 <li><a name="toc-Where-can-I-find-libav_002a-headers-for-Pascal_002fDelphi_003f" href="#Where-can-I-find-libav_002a-headers-for-Pascal_002fDelphi_003f">4.14 Where can I find libav* headers for Pascal/Delphi?</a></li>
104 <li><a name="toc-Where-is-the-documentation-about-ffv1_002c-msmpeg4_002c-asv1_002c-4xm_003f" href="#Where-is-the-documentation-about-ffv1_002c-msmpeg4_002c-asv1_002c-4xm_003f">4.15 Where is the documentation about ffv1, msmpeg4, asv1, 4xm?</a></li>
105 <li><a name="toc-How-do-I-feed-H_002e263_002dRTP-_0028and-other-codecs-in-RTP_0029-to-libavcodec_003f" href="#How-do-I-feed-H_002e263_002dRTP-_0028and-other-codecs-in-RTP_0029-to-libavcodec_003f">4.16 How do I feed H.263-RTP (and other codecs in RTP) to libavcodec?</a></li>
106 <li><a name="toc-AVStream_002er_005fframe_005frate-is-wrong_002c-it-is-much-larger-than-the-framerate_002e" href="#AVStream_002er_005fframe_005frate-is-wrong_002c-it-is-much-larger-than-the-framerate_002e">4.17 AVStream.r_frame_rate is wrong, it is much larger than the framerate.</a></li>
113 <a name="General-Questions"></a>
114 <h1 class="chapter"><a href="faq.html#toc-General-Questions">1. General Questions</a></h1>
116 <a name="When-will-the-next-FFmpeg-version-be-released_003f-_002f-Why-are-FFmpeg-releases-so-few-and-far-between_003f"></a>
117 <h2 class="section"><a href="faq.html#toc-When-will-the-next-FFmpeg-version-be-released_003f-_002f-Why-are-FFmpeg-releases-so-few-and-far-between_003f">1.1 When will the next FFmpeg version be released? / Why are FFmpeg releases so few and far between?</a></h2>
119 <p>Like most open source projects FFmpeg suffers from a certain lack of
120 manpower. For this reason the developers have to prioritize the work
121 they do and putting out releases is not at the top of the list, fixing
122 bugs and reviewing patches takes precedence. Please don’t complain or
123 request more timely and/or frequent releases unless you are willing to
124 help out creating them.
126 <a name="I-have-a-problem-with-an-old-version-of-FFmpeg_003b-where-should-I-report-it_003f"></a>
127 <h2 class="section"><a href="faq.html#toc-I-have-a-problem-with-an-old-version-of-FFmpeg_003b-where-should-I-report-it_003f">1.2 I have a problem with an old version of FFmpeg; where should I report it?</a></h2>
128 <p>Nowhere. We do not support old FFmpeg versions in any way, we simply lack
129 the time, motivation and manpower to do so. If you have a problem with an
130 old version of FFmpeg, upgrade to the latest git snapshot. If you
131 still experience the problem, then you can report it according to the
132 guidelines in <a href="http://ffmpeg.org/bugreports.html">http://ffmpeg.org/bugreports.html</a>.
134 <a name="Why-doesn_0027t-FFmpeg-support-feature-_005bxyz_005d_003f"></a>
135 <h2 class="section"><a href="faq.html#toc-Why-doesn_0027t-FFmpeg-support-feature-_005bxyz_005d_003f">1.3 Why doesn’t FFmpeg support feature [xyz]?</a></h2>
137 <p>Because no one has taken on that task yet. FFmpeg development is
138 driven by the tasks that are important to the individual developers.
139 If there is a feature that is important to you, the best way to get
140 it implemented is to undertake the task yourself or sponsor a developer.
142 <a name="FFmpeg-does-not-support-codec-XXX_002e-Can-you-include-a-Windows-DLL-loader-to-support-it_003f"></a>
143 <h2 class="section"><a href="faq.html#toc-FFmpeg-does-not-support-codec-XXX_002e-Can-you-include-a-Windows-DLL-loader-to-support-it_003f">1.4 FFmpeg does not support codec XXX. Can you include a Windows DLL loader to support it?</a></h2>
145 <p>No. Windows DLLs are not portable, bloated and often slow.
146 Moreover FFmpeg strives to support all codecs natively.
147 A DLL loader is not conducive to that goal.
149 <a name="My-bug-report_002fmail-to-ffmpeg_002ddevel_002fuser-has-not-received-any-replies_002e"></a>
150 <h2 class="section"><a href="faq.html#toc-My-bug-report_002fmail-to-ffmpeg_002ddevel_002fuser-has-not-received-any-replies_002e">1.5 My bug report/mail to ffmpeg-devel/user has not received any replies.</a></h2>
154 <li> We are busy and haven’t had time yet to read your report or
155 investigate the issue.
156 </li><li> You didn’t follow <a href="http://ffmpeg.org/bugreports.html">http://ffmpeg.org/bugreports.html</a>.
157 </li><li> You didn’t use git master.
158 </li><li> You reported a segmentation fault without gdb output.
159 </li><li> You describe a problem but not how to reproduce it.
160 </li><li> It’s unclear if you use ffmpeg as command line tool or use
161 libav* from another application.
162 </li><li> You speak about a video having problems on playback but
163 not what you use to play it.
164 </li><li> We have no faint clue what you are talking about besides
165 that it is related to FFmpeg.
168 <a name="Is-there-a-forum-for-FFmpeg_003f-I-do-not-like-mailing-lists_002e"></a>
169 <h2 class="section"><a href="faq.html#toc-Is-there-a-forum-for-FFmpeg_003f-I-do-not-like-mailing-lists_002e">1.6 Is there a forum for FFmpeg? I do not like mailing lists.</a></h2>
171 <p>You may view our mailing lists with a more forum-alike look here:
172 <a href="http://dir.gmane.org/gmane.comp.video.ffmpeg.user">http://dir.gmane.org/gmane.comp.video.ffmpeg.user</a>,
173 but, if you post, please remember that our mailing list rules still apply there.
175 <a name="I-cannot-read-this-file-although-this-format-seems-to-be-supported-by-ffmpeg_002e"></a>
176 <h2 class="section"><a href="faq.html#toc-I-cannot-read-this-file-although-this-format-seems-to-be-supported-by-ffmpeg_002e">1.7 I cannot read this file although this format seems to be supported by ffmpeg.</a></h2>
178 <p>Even if ffmpeg can read the container format, it may not support all its
179 codecs. Please consult the supported codec list in the ffmpeg
182 <a name="Which-codecs-are-supported-by-Windows_003f"></a>
183 <h2 class="section"><a href="faq.html#toc-Which-codecs-are-supported-by-Windows_003f">1.8 Which codecs are supported by Windows?</a></h2>
185 <p>Windows does not support standard formats like MPEG very well, unless you
186 install some additional codecs.
188 <p>The following list of video codecs should work on most Windows systems:
189 </p><dl compact="compact">
190 <dt> ‘<samp>msmpeg4v2</samp>’</dt>
193 <dt> ‘<samp>msmpeg4</samp>’</dt>
196 <dt> ‘<samp>wmv1</samp>’</dt>
199 <dt> ‘<samp>wmv2</samp>’</dt>
202 <dt> ‘<samp>mpeg4</samp>’</dt>
203 <dd><p>Only if you have some MPEG-4 codec like ffdshow or Xvid installed.
205 <dt> ‘<samp>mpeg1video</samp>’</dt>
209 <p>Note, ASF files often have .wmv or .wma extensions in Windows. It should also
210 be mentioned that Microsoft claims a patent on the ASF format, and may sue
211 or threaten users who create ASF files with non-Microsoft software. It is
212 strongly advised to avoid ASF where possible.
214 <p>The following list of audio codecs should work on most Windows systems:
215 </p><dl compact="compact">
216 <dt> ‘<samp>adpcm_ima_wav</samp>’</dt>
217 <dt> ‘<samp>adpcm_ms</samp>’</dt>
218 <dt> ‘<samp>pcm_s16le</samp>’</dt>
221 <dt> ‘<samp>libmp3lame</samp>’</dt>
222 <dd><p>If some MP3 codec like LAME is installed.
227 <a name="Compilation"></a>
228 <h1 class="chapter"><a href="faq.html#toc-Compilation">2. Compilation</a></h1>
230 <a name="error_003a-can_0027t-find-a-register-in-class-_0027GENERAL_005fREGS_0027-while-reloading-_0027asm_0027"></a>
231 <h2 class="section"><a href="faq.html#toc-error_003a-can_0027t-find-a-register-in-class-_0027GENERAL_005fREGS_0027-while-reloading-_0027asm_0027">2.1 <code>error: can't find a register in class 'GENERAL_REGS' while reloading 'asm'</code></a></h2>
233 <p>This is a bug in gcc. Do not report it to us. Instead, please report it to
234 the gcc developers. Note that we will not add workarounds for gcc bugs.
236 <p>Also note that (some of) the gcc developers believe this is not a bug or
237 not a bug they should fix:
238 <a href="http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11203">http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11203</a>.
239 Then again, some of them do not know the difference between an undecidable
240 problem and an NP-hard problem...
243 <h1 class="chapter"><a href="faq.html#toc-Usage">3. Usage</a></h1>
245 <a name="ffmpeg-does-not-work_003b-what-is-wrong_003f"></a>
246 <h2 class="section"><a href="faq.html#toc-ffmpeg-does-not-work_003b-what-is-wrong_003f">3.1 ffmpeg does not work; what is wrong?</a></h2>
248 <p>Try a <code>make distclean</code> in the ffmpeg source directory before the build.
249 If this does not help see
250 (<a href="http://ffmpeg.org/bugreports.html">http://ffmpeg.org/bugreports.html</a>).
252 <a name="How-do-I-encode-single-pictures-into-movies_003f"></a>
253 <h2 class="section"><a href="faq.html#toc-How-do-I-encode-single-pictures-into-movies_003f">3.2 How do I encode single pictures into movies?</a></h2>
255 <p>First, rename your pictures to follow a numerical sequence.
256 For example, img1.jpg, img2.jpg, img3.jpg,...
259 <table><tr><td> </td><td><pre class="example"> ffmpeg -f image2 -i img%d.jpg /tmp/a.mpg
260 </pre></td></tr></table>
262 <p>Notice that ‘<samp>%d</samp>’ is replaced by the image number.
264 <p>‘<tt>img%03d.jpg</tt>’ means the sequence ‘<tt>img001.jpg</tt>’, ‘<tt>img002.jpg</tt>’, etc...
266 <p>If you have large number of pictures to rename, you can use the
267 following command to ease the burden. The command, using the bourne
268 shell syntax, symbolically links all files in the current directory
269 that match <code>*jpg</code> to the ‘<tt>/tmp</tt>’ directory in the sequence of
270 ‘<tt>img001.jpg</tt>’, ‘<tt>img002.jpg</tt>’ and so on.
272 <table><tr><td> </td><td><pre class="example"> x=1; for i in *jpg; do counter=$(printf %03d $x); ln -s "$i" /tmp/img"$counter".jpg; x=$(($x+1)); done
273 </pre></td></tr></table>
275 <p>If you want to sequence them by oldest modified first, substitute
276 <code>$(ls -r -t *jpg)</code> in place of <code>*jpg</code>.
280 <table><tr><td> </td><td><pre class="example"> ffmpeg -f image2 -i /tmp/img%03d.jpg /tmp/a.mpg
281 </pre></td></tr></table>
283 <p>The same logic is used for any image format that ffmpeg reads.
285 <a name="How-do-I-encode-movie-to-single-pictures_003f"></a>
286 <h2 class="section"><a href="faq.html#toc-How-do-I-encode-movie-to-single-pictures_003f">3.3 How do I encode movie to single pictures?</a></h2>
290 <table><tr><td> </td><td><pre class="example"> ffmpeg -i movie.mpg movie%d.jpg
291 </pre></td></tr></table>
293 <p>The ‘<tt>movie.mpg</tt>’ used as input will be converted to
294 ‘<tt>movie1.jpg</tt>’, ‘<tt>movie2.jpg</tt>’, etc...
296 <p>Instead of relying on file format self-recognition, you may also use
297 </p><dl compact="compact">
298 <dt> ‘<samp>-vcodec ppm</samp>’</dt>
299 <dt> ‘<samp>-vcodec png</samp>’</dt>
300 <dt> ‘<samp>-vcodec mjpeg</samp>’</dt>
302 <p>to force the encoding.
304 <p>Applying that to the previous example:
305 </p><table><tr><td> </td><td><pre class="example"> ffmpeg -i movie.mpg -f image2 -vcodec mjpeg menu%d.jpg
306 </pre></td></tr></table>
308 <p>Beware that there is no "jpeg" codec. Use "mjpeg" instead.
310 <a name="Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f"></a>
311 <h2 class="section"><a href="faq.html#toc-Why-do-I-see-a-slight-quality-degradation-with-multithreaded-MPEG_002a-encoding_003f">3.4 Why do I see a slight quality degradation with multithreaded MPEG* encoding?</a></h2>
313 <p>For multithreaded MPEG* encoding, the encoded slices must be independent,
314 otherwise thread n would practically have to wait for n-1 to finish, so it’s
315 quite logical that there is a small reduction of quality. This is not a bug.
317 <a name="How-can-I-read-from-the-standard-input-or-write-to-the-standard-output_003f"></a>
318 <h2 class="section"><a href="faq.html#toc-How-can-I-read-from-the-standard-input-or-write-to-the-standard-output_003f">3.5 How can I read from the standard input or write to the standard output?</a></h2>
320 <p>Use ‘<tt>-</tt>’ as file name.
322 <a name="g_t_002df-jpeg-doesn_0027t-work_002e"></a>
323 <h2 class="section"><a href="faq.html#toc-_002df-jpeg-doesn_0027t-work_002e">3.6 -f jpeg doesn’t work.</a></h2>
325 <p>Try ’-f image2 test%d.jpg’.
327 <a name="Why-can-I-not-change-the-framerate_003f"></a>
328 <h2 class="section"><a href="faq.html#toc-Why-can-I-not-change-the-framerate_003f">3.7 Why can I not change the framerate?</a></h2>
330 <p>Some codecs, like MPEG-1/2, only allow a small number of fixed framerates.
331 Choose a different codec with the -vcodec command line option.
333 <a name="How-do-I-encode-Xvid-or-DivX-video-with-ffmpeg_003f"></a>
334 <h2 class="section"><a href="faq.html#toc-How-do-I-encode-Xvid-or-DivX-video-with-ffmpeg_003f">3.8 How do I encode Xvid or DivX video with ffmpeg?</a></h2>
336 <p>Both Xvid and DivX (version 4+) are implementations of the ISO MPEG-4
337 standard (note that there are many other coding formats that use this
338 same standard). Thus, use ’-vcodec mpeg4’ to encode in these formats. The
339 default fourcc stored in an MPEG-4-coded file will be ’FMP4’. If you want
340 a different fourcc, use the ’-vtag’ option. E.g., ’-vtag xvid’ will
341 force the fourcc ’xvid’ to be stored as the video fourcc rather than the
344 <a name="How-do-I-encode-videos-which-play-on-the-iPod_003f"></a>
345 <h2 class="section"><a href="faq.html#toc-How-do-I-encode-videos-which-play-on-the-iPod_003f">3.9 How do I encode videos which play on the iPod?</a></h2>
347 <dl compact="compact">
348 <dt> ‘<samp>needed stuff</samp>’</dt>
349 <dd><p>-acodec libfaac -vcodec mpeg4 width<=320 height<=240
351 <dt> ‘<samp>working stuff</samp>’</dt>
354 <dt> ‘<samp>non-working stuff</samp>’</dt>
357 <dt> ‘<samp>example command line</samp>’</dt>
358 <dd><p>ffmpeg -i input -acodec libfaac -ab 128k -vcodec mpeg4 -b 1200k -mbd 2 -flags +mv4+aic -trellis 2 -cmp 2 -subcmp 2 -s 320x180 -metadata title=X output.mp4
362 <a name="How-do-I-encode-videos-which-play-on-the-PSP_003f"></a>
363 <h2 class="section"><a href="faq.html#toc-How-do-I-encode-videos-which-play-on-the-PSP_003f">3.10 How do I encode videos which play on the PSP?</a></h2>
365 <dl compact="compact">
366 <dt> ‘<samp>needed stuff</samp>’</dt>
367 <dd><p>-acodec libfaac -vcodec mpeg4 width*height<=76800 width%16=0 height%16=0 -ar 24000 -r 30000/1001 or 15000/1001 -f psp
369 <dt> ‘<samp>working stuff</samp>’</dt>
372 <dt> ‘<samp>non-working stuff</samp>’</dt>
375 <dt> ‘<samp>example command line</samp>’</dt>
376 <dd><p>ffmpeg -i input -acodec libfaac -ab 128k -vcodec mpeg4 -b 1200k -ar 24000 -mbd 2 -flags +mv4+aic -trellis 2 -cmp 2 -subcmp 2 -s 368x192 -r 30000/1001 -metadata title=X -f psp output.mp4
378 <dt> ‘<samp>needed stuff for H.264</samp>’</dt>
379 <dd><p>-acodec libfaac -vcodec libx264 width*height<=76800 width%16=0? height%16=0? -ar 48000 -coder 1 -r 30000/1001 or 15000/1001 -f psp
381 <dt> ‘<samp>working stuff for H.264</samp>’</dt>
382 <dd><p>title, loop filter
384 <dt> ‘<samp>non-working stuff for H.264</samp>’</dt>
387 <dt> ‘<samp>example command line</samp>’</dt>
388 <dd><p>ffmpeg -i input -acodec libfaac -ab 128k -vcodec libx264 -b 1200k -ar 48000 -mbd 2 -coder 1 -cmp 2 -subcmp 2 -s 368x192 -r 30000/1001 -metadata title=X -f psp -flags loop -trellis 2 -partitions parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 output.mp4
390 <dt> ‘<samp>higher resolution for newer PSP firmwares, width<=480, height<=272</samp>’</dt>
391 <dd><p>-vcodec libx264 -level 21 -coder 1 -f psp
393 <dt> ‘<samp>example command line</samp>’</dt>
394 <dd><p>ffmpeg -i input -acodec libfaac -ab 128k -ac 2 -ar 48000 -vcodec libx264 -level 21 -b 640k -coder 1 -f psp -flags +loop -trellis 2 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -g 250 -s 480x272 output.mp4
398 <a name="Which-are-good-parameters-for-encoding-high-quality-MPEG_002d4_003f"></a>
399 <h2 class="section"><a href="faq.html#toc-Which-are-good-parameters-for-encoding-high-quality-MPEG_002d4_003f">3.11 Which are good parameters for encoding high quality MPEG-4?</a></h2>
401 <p>’-mbd rd -flags +mv4+aic -trellis 2 -cmp 2 -subcmp 2 -g 300 -pass 1/2’,
402 things to try: ’-bf 2’, ’-flags qprd’, ’-flags mv0’, ’-flags skiprd’.
404 <a name="Which-are-good-parameters-for-encoding-high-quality-MPEG_002d1_002fMPEG_002d2_003f"></a>
405 <h2 class="section"><a href="faq.html#toc-Which-are-good-parameters-for-encoding-high-quality-MPEG_002d1_002fMPEG_002d2_003f">3.12 Which are good parameters for encoding high quality MPEG-1/MPEG-2?</a></h2>
407 <p>’-mbd rd -trellis 2 -cmp 2 -subcmp 2 -g 100 -pass 1/2’
408 but beware the ’-g 100’ might cause problems with some decoders.
409 Things to try: ’-bf 2’, ’-flags qprd’, ’-flags mv0’, ’-flags skiprd.
411 <a name="Interlaced-video-looks-very-bad-when-encoded-with-ffmpeg_002c-what-is-wrong_003f"></a>
412 <h2 class="section"><a href="faq.html#toc-Interlaced-video-looks-very-bad-when-encoded-with-ffmpeg_002c-what-is-wrong_003f">3.13 Interlaced video looks very bad when encoded with ffmpeg, what is wrong?</a></h2>
414 <p>You should use ’-flags +ilme+ildct’ and maybe ’-flags +alt’ for interlaced
415 material, and try ’-top 0/1’ if the result looks really messed-up.
417 <a name="How-can-I-read-DirectShow-files_003f"></a>
418 <h2 class="section"><a href="faq.html#toc-How-can-I-read-DirectShow-files_003f">3.14 How can I read DirectShow files?</a></h2>
420 <p>If you have built FFmpeg with <code>./configure --enable-avisynth</code>
421 (only possible on MinGW/Cygwin platforms),
422 then you may use any file that DirectShow can read as input.
424 <p>Just create an "input.avs" text file with this single line ...
425 </p><table><tr><td> </td><td><pre class="example"> DirectShowSource("C:\path to your file\yourfile.asf")
426 </pre></td></tr></table>
427 <p>... and then feed that text file to ffmpeg:
428 </p><table><tr><td> </td><td><pre class="example"> ffmpeg -i input.avs
429 </pre></td></tr></table>
431 <p>For ANY other help on Avisynth, please visit the
432 <a href="http://www.avisynth.org/">Avisynth homepage</a>.
434 <a name="How-can-I-join-video-files_003f"></a>
435 <h2 class="section"><a href="faq.html#toc-How-can-I-join-video-files_003f">3.15 How can I join video files?</a></h2>
437 <p>A few multimedia containers (MPEG-1, MPEG-2 PS, DV) allow to join video files by
438 merely concatenating them.
440 <p>Hence you may concatenate your multimedia files by first transcoding them to
441 these privileged formats, then using the humble <code>cat</code> command (or the
442 equally humble <code>copy</code> under Windows), and finally transcoding back to your
445 <table><tr><td> </td><td><pre class="example">ffmpeg -i input1.avi -sameq intermediate1.mpg
446 ffmpeg -i input2.avi -sameq intermediate2.mpg
447 cat intermediate1.mpg intermediate2.mpg > intermediate_all.mpg
448 ffmpeg -i intermediate_all.mpg -sameq output.avi
449 </pre></td></tr></table>
451 <p>Notice that you should either use <code>-sameq</code> or set a reasonably high
452 bitrate for your intermediate and output files, if you want to preserve
455 <p>Also notice that you may avoid the huge intermediate files by taking advantage
456 of named pipes, should your platform support it:
458 <table><tr><td> </td><td><pre class="example">mkfifo intermediate1.mpg
459 mkfifo intermediate2.mpg
460 ffmpeg -i input1.avi -sameq -y intermediate1.mpg < /dev/null &
461 ffmpeg -i input2.avi -sameq -y intermediate2.mpg < /dev/null &
462 cat intermediate1.mpg intermediate2.mpg |\
463 ffmpeg -f mpeg -i - -sameq -vcodec mpeg4 -acodec libmp3lame output.avi
464 </pre></td></tr></table>
466 <p>Similarly, the yuv4mpegpipe format, and the raw video, raw audio codecs also
467 allow concatenation, and the transcoding step is almost lossless.
468 When using multiple yuv4mpegpipe(s), the first line needs to be discarded
469 from all but the first stream. This can be accomplished by piping through
470 <code>tail</code> as seen below. Note that when piping through <code>tail</code> you
471 must use command grouping, <code>{ ;}</code>, to background properly.
473 <p>For example, let’s say we want to join two FLV files into an output.flv file:
475 <table><tr><td> </td><td><pre class="example">mkfifo temp1.a
481 ffmpeg -i input1.flv -vn -f u16le -acodec pcm_s16le -ac 2 -ar 44100 - > temp1.a < /dev/null &
482 ffmpeg -i input2.flv -vn -f u16le -acodec pcm_s16le -ac 2 -ar 44100 - > temp2.a < /dev/null &
483 ffmpeg -i input1.flv -an -f yuv4mpegpipe - > temp1.v < /dev/null &
484 { ffmpeg -i input2.flv -an -f yuv4mpegpipe - < /dev/null | tail -n +2 > temp2.v ; } &
485 cat temp1.a temp2.a > all.a &
486 cat temp1.v temp2.v > all.v &
487 ffmpeg -f u16le -acodec pcm_s16le -ac 2 -ar 44100 -i all.a \
488 -f yuv4mpegpipe -i all.v \
490 rm temp[12].[av] all.[av]
491 </pre></td></tr></table>
493 <a name="The-ffmpeg-program-does-not-respect-the-_002dmaxrate-setting_002c-some-frames-are-bigger-than-maxrate_002ffps_002e"></a>
494 <h2 class="section"><a href="faq.html#toc-The-ffmpeg-program-does-not-respect-the-_002dmaxrate-setting_002c-some-frames-are-bigger-than-maxrate_002ffps_002e">3.16 The ffmpeg program does not respect the -maxrate setting, some frames are bigger than maxrate/fps.</a></h2>
496 <p>Read the MPEG spec about video buffer verifier.
498 <a name="I-want-CBR_002c-but-no-matter-what-I-do-frame-sizes-differ_002e"></a>
499 <h2 class="section"><a href="faq.html#toc-I-want-CBR_002c-but-no-matter-what-I-do-frame-sizes-differ_002e">3.17 I want CBR, but no matter what I do frame sizes differ.</a></h2>
501 <p>You do not understand what CBR is, please read the MPEG spec.
502 Read about video buffer verifier and constant bitrate.
503 The one sentence summary is that there is a buffer and the input rate is
504 constant, the output can vary as needed.
506 <a name="How-do-I-check-if-a-stream-is-CBR_003f"></a>
507 <h2 class="section"><a href="faq.html#toc-How-do-I-check-if-a-stream-is-CBR_003f">3.18 How do I check if a stream is CBR?</a></h2>
509 <p>To quote the MPEG-2 spec:
510 "There is no way to tell that a bitstream is constant bitrate without
511 examining all of the vbv_delay values and making complicated computations."
514 <a name="Development"></a>
515 <h1 class="chapter"><a href="faq.html#toc-Development">4. Development</a></h1>
517 <a name="Are-there-examples-illustrating-how-to-use-the-FFmpeg-libraries_002c-particularly-libavcodec-and-libavformat_003f"></a>
518 <h2 class="section"><a href="faq.html#toc-Are-there-examples-illustrating-how-to-use-the-FFmpeg-libraries_002c-particularly-libavcodec-and-libavformat_003f">4.1 Are there examples illustrating how to use the FFmpeg libraries, particularly libavcodec and libavformat?</a></h2>
520 <p>Yes. Read the Developers Guide of the FFmpeg documentation. Alternatively,
521 examine the source code for one of the many open source projects that
522 already incorporate FFmpeg at (<a href="projects.html">projects.html</a>).
524 <a name="Can-you-support-my-C-compiler-XXX_003f"></a>
525 <h2 class="section"><a href="faq.html#toc-Can-you-support-my-C-compiler-XXX_003f">4.2 Can you support my C compiler XXX?</a></h2>
527 <p>It depends. If your compiler is C99-compliant, then patches to support
528 it are likely to be welcome if they do not pollute the source code
529 with <code>#ifdef</code>s related to the compiler.
531 <a name="Is-Microsoft-Visual-C_002b_002b-supported_003f"></a>
532 <h2 class="section"><a href="faq.html#toc-Is-Microsoft-Visual-C_002b_002b-supported_003f">4.3 Is Microsoft Visual C++ supported?</a></h2>
534 <p>No. Microsoft Visual C++ is not compliant to the C99 standard and does
535 not - among other things - support the inline assembly used in FFmpeg.
536 If you wish to use MSVC++ for your
537 project then you can link the MSVC++ code with libav* as long as
538 you compile the latter with a working C compiler. For more information, see
539 the <em>Microsoft Visual C++ compatibility</em> section in the FFmpeg
542 <p>There have been efforts to make FFmpeg compatible with MSVC++ in the
543 past. However, they have all been rejected as too intrusive, especially
544 since MinGW does the job adequately. None of the core developers
545 work with MSVC++ and thus this item is low priority. Should you find
546 the silver bullet that solves this problem, feel free to shoot it at us.
548 <p>We strongly recommend you to move over from MSVC++ to MinGW tools.
550 <a name="Can-I-use-FFmpeg-or-libavcodec-under-Windows_003f"></a>
551 <h2 class="section"><a href="faq.html#toc-Can-I-use-FFmpeg-or-libavcodec-under-Windows_003f">4.4 Can I use FFmpeg or libavcodec under Windows?</a></h2>
553 <p>Yes, but the Cygwin or MinGW tools <em>must</em> be used to compile FFmpeg.
554 Read the <em>Windows</em> section in the FFmpeg documentation to find more
557 <p>To get help and instructions for building FFmpeg under Windows, check out
558 the FFmpeg Windows Help Forum at
559 <a href="http://ffmpeg.arrozcru.org/">http://ffmpeg.arrozcru.org/</a>.
561 <a name="Can-you-add-automake_002c-libtool-or-autoconf-support_003f"></a>
562 <h2 class="section"><a href="faq.html#toc-Can-you-add-automake_002c-libtool-or-autoconf-support_003f">4.5 Can you add automake, libtool or autoconf support?</a></h2>
564 <p>No. These tools are too bloated and they complicate the build.
566 <a name="Why-not-rewrite-ffmpeg-in-object_002doriented-C_002b_002b_003f"></a>
567 <h2 class="section"><a href="faq.html#toc-Why-not-rewrite-ffmpeg-in-object_002doriented-C_002b_002b_003f">4.6 Why not rewrite ffmpeg in object-oriented C++?</a></h2>
569 <p>FFmpeg is already organized in a highly modular manner and does not need to
570 be rewritten in a formal object language. Further, many of the developers
571 favor straight C; it works for them. For more arguments on this matter,
572 read <a href="http://www.tux.org/lkml/#s15">"Programming Religion"</a>.
574 <a name="Why-are-the-ffmpeg-programs-devoid-of-debugging-symbols_003f"></a>
575 <h2 class="section"><a href="faq.html#toc-Why-are-the-ffmpeg-programs-devoid-of-debugging-symbols_003f">4.7 Why are the ffmpeg programs devoid of debugging symbols?</a></h2>
577 <p>The build process creates ffmpeg_g, ffplay_g, etc. which contain full debug
578 information. Those binaries are stripped to create ffmpeg, ffplay, etc. If
579 you need the debug information, use the *_g versions.
581 <a name="I-do-not-like-the-LGPL_002c-can-I-contribute-code-under-the-GPL-instead_003f"></a>
582 <h2 class="section"><a href="faq.html#toc-I-do-not-like-the-LGPL_002c-can-I-contribute-code-under-the-GPL-instead_003f">4.8 I do not like the LGPL, can I contribute code under the GPL instead?</a></h2>
584 <p>Yes, as long as the code is optional and can easily and cleanly be placed
585 under #if CONFIG_GPL without breaking anything. So for example a new codec
586 or filter would be OK under GPL while a bug fix to LGPL code would not.
588 <a name="I-want-to-compile-xyz_002ec-alone-but-my-compiler-produced-many-errors_002e"></a>
589 <h2 class="section"><a href="faq.html#toc-I-want-to-compile-xyz_002ec-alone-but-my-compiler-produced-many-errors_002e">4.9 I want to compile xyz.c alone but my compiler produced many errors.</a></h2>
591 <p>Common code is in its own files in libav* and is used by the individual
592 codecs. They will not work without the common parts, you have to compile
593 the whole libav*. If you wish, disable some parts with configure switches.
594 You can also try to hack it and remove more, but if you had problems fixing
595 the compilation failure then you are probably not qualified for this.
597 <a name="I_0027m-using-libavcodec-from-within-my-C_002b_002b-application-but-the-linker-complains-about-missing-symbols-which-seem-to-be-available_002e"></a>
598 <h2 class="section"><a href="faq.html#toc-I_0027m-using-libavcodec-from-within-my-C_002b_002b-application-but-the-linker-complains-about-missing-symbols-which-seem-to-be-available_002e">4.10 I’m using libavcodec from within my C++ application but the linker complains about missing symbols which seem to be available.</a></h2>
600 <p>FFmpeg is a pure C project, so to use the libraries within your C++ application
601 you need to explicitly state that you are using a C library. You can do this by
602 encompassing your FFmpeg includes using <code>extern "C"</code>.
604 <p>See <a href="http://www.parashift.com/c++-faq-lite/mixing-c-and-cpp.html#faq-32.3">http://www.parashift.com/c++-faq-lite/mixing-c-and-cpp.html#faq-32.3</a>
606 <a name="I-have-a-file-in-memory-_002f-a-API-different-from-_002aopen_002f_002aread_002f-libc-how-do-I-use-it-with-libavformat_003f"></a>
607 <h2 class="section"><a href="faq.html#toc-I-have-a-file-in-memory-_002f-a-API-different-from-_002aopen_002f_002aread_002f-libc-how-do-I-use-it-with-libavformat_003f">4.11 I have a file in memory / a API different from *open/*read/ libc how do I use it with libavformat?</a></h2>
609 <p>You have to implement a URLProtocol, see ‘<tt>libavformat/file.c</tt>’ in
610 FFmpeg and ‘<tt>libmpdemux/demux_lavf.c</tt>’ in MPlayer sources.
612 <a name="I-get-_0022No-compatible-shell-script-interpreter-found_002e_0022-in-MSys_002e"></a>
613 <h2 class="section"><a href="faq.html#toc-I-get-_0022No-compatible-shell-script-interpreter-found_002e_0022-in-MSys_002e">4.12 I get "No compatible shell script interpreter found." in MSys.</a></h2>
615 <p>The standard MSys bash (2.04) is broken. You need to install 2.05 or later.
617 <a name="I-get-_0022_002e_002fconfigure_003a-line-_003cxxx_003e_003a-pr_003a-command-not-found_0022-in-MSys_002e"></a>
618 <h2 class="section"><a href="faq.html#toc-I-get-_0022_002e_002fconfigure_003a-line-_003cxxx_003e_003a-pr_003a-command-not-found_0022-in-MSys_002e">4.13 I get "./configure: line <xxx>: pr: command not found" in MSys.</a></h2>
620 <p>The standard MSys install doesn’t come with pr. You need to get it from the coreutils package.
622 <a name="Where-can-I-find-libav_002a-headers-for-Pascal_002fDelphi_003f"></a>
623 <h2 class="section"><a href="faq.html#toc-Where-can-I-find-libav_002a-headers-for-Pascal_002fDelphi_003f">4.14 Where can I find libav* headers for Pascal/Delphi?</a></h2>
625 <p>see <a href="http://www.iversenit.dk/dev/ffmpeg-headers/">http://www.iversenit.dk/dev/ffmpeg-headers/</a>
627 <a name="Where-is-the-documentation-about-ffv1_002c-msmpeg4_002c-asv1_002c-4xm_003f"></a>
628 <h2 class="section"><a href="faq.html#toc-Where-is-the-documentation-about-ffv1_002c-msmpeg4_002c-asv1_002c-4xm_003f">4.15 Where is the documentation about ffv1, msmpeg4, asv1, 4xm?</a></h2>
630 <p>see <a href="http://www.ffmpeg.org/~michael/">http://www.ffmpeg.org/~michael/</a>
632 <a name="How-do-I-feed-H_002e263_002dRTP-_0028and-other-codecs-in-RTP_0029-to-libavcodec_003f"></a>
633 <h2 class="section"><a href="faq.html#toc-How-do-I-feed-H_002e263_002dRTP-_0028and-other-codecs-in-RTP_0029-to-libavcodec_003f">4.16 How do I feed H.263-RTP (and other codecs in RTP) to libavcodec?</a></h2>
635 <p>Even if peculiar since it is network oriented, RTP is a container like any
636 other. You have to <em>demux</em> RTP before feeding the payload to libavcodec.
637 In this specific case please look at RFC 4629 to see how it should be done.
639 <a name="AVStream_002er_005fframe_005frate-is-wrong_002c-it-is-much-larger-than-the-framerate_002e"></a>
640 <h2 class="section"><a href="faq.html#toc-AVStream_002er_005fframe_005frate-is-wrong_002c-it-is-much-larger-than-the-framerate_002e">4.17 AVStream.r_frame_rate is wrong, it is much larger than the framerate.</a></h2>
642 <p>r_frame_rate is NOT the average framerate, it is the smallest framerate
643 that can accurately represent all timestamps. So no, it is not
644 wrong if it is larger than the average!
645 For example, if you have mixed 25 and 30 fps content, then r_frame_rate
651 This document was generated by <em>Kyle Schwarz</em> on <em>September 2, 2011</em> using <a href="http://www.nongnu.org/texi2html/"><em>texi2html 1.82</em></a>.