Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Take a look <a href="http://sgros.blogspot.co.il/2013/01/deprecated-functions-in-ffmpeg-library.html" rel="nofollow noreferrer">here</a>.</p> <pre><code>URL_WRONLY -&gt; AVIO_FLAG_WRITE url_fopen -&gt; avio_open url_fclose -&gt; avio_close </code></pre> <p>Hope the above is enough to get you started.</p> <hr/> <p>In case the link doesn't survive, here is the full text transcript:</p> <blockquote> <p>I found some resources about how to port old code (<a href="http://ffmpeg.org/doxygen/trunk/deprecated.html" rel="nofollow noreferrer">here</a>, <a href="http://tom.webarts.ca/Blog/new-blog-items/buildingzoneminderandrequiredffmpegandx264fromsource" rel="nofollow noreferrer">here</a> and <a href="http://code.opencv.org/issues/1605" rel="nofollow noreferrer">here</a>), but since it wasn't what I needed I decided to write my own version. So, here we go.</p> <p><code>url_open()</code></p> <p>This function has been changed to avio_open. There is also url_close which is renamed to avio_close. This information I found here.</p> <p><code>av_new_stream()</code></p> <p>This function is still supported as of FFMPEG 1.0.1 but it is marked as deprecated. It will be replaced with avformat_new_stream(). Suppose that the old code was:</p> <pre><code>AVStream *st = av_new_stream(oc, i); </code></pre> <p>the modified code should be:</p> <pre><code>AVStream *st = avformat_new_stream(oc, NULL); st-&gt;id = i </code></pre> <p>Be careful to check first that st isn't NULL!</p> <p><code>dump_format()</code></p> <p>This function was renamed to av_dump_format().</p> <p><code>av_write_header()</code></p> <p>Replaced with avformat_write_header() that accepts two arguments instead of one. Pass NULL as the second argument to get identical behavior to the old function.</p> <p><code>av_codec_open()</code></p> <p>This one is replaced with av_codec_open2(). The replacement function accepts three arguments instead of two, but put NULL as a third argument to get the same behavior as the old function.</p> <p><code>avcodec_encode_audio()</code></p> <p>Replaced with avcodec_encode_audio2().</p> <p><code>av_set_parameters()</code></p> <p>I couldn't fine the replacement for this one. First, I've found that this function doesn't have replacement. But it was when it was still available in FFMPEG, even though deprecated. Then, they removed it, and thus it has to have replacement. In certain places I found that they only disabled it, on others that its parameters have to be passed to avformat_write_header. In the end, I gave up because I didn't need working version of that part of the code for now. Since in my case avformat_alloc_context() is called and then av_set_parameters(), last what I looked at was to call avformat_alloc_output_context2() instead of avformat_alloc_context(). But the change is not trivial so I skipped it.</p> <p><code>SampleFormat</code></p> <p>This enum has been renamed AVSampleFormat.</p> <p><code>URL_WRONLY</code> </p> <p>This constant has been replaced with AVIO_FLAG_WRITE.</p> <p><code>SAMPLE_FMT_U8, SAMPLE_FMT_S16, SAMPLE_FMT_S32, etc.</code></p> <p>Those are prefixed now with AV_, so use AV_SAMPLE_FMT_U8, AV_SAMPLE_FMT_S16, etc.</p> </blockquote>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload