<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Aug 18, 2016 at 4:02 PM, Charles <span dir="ltr"><<a href="mailto:linux2@orion15.org" target="_blank">linux2@orion15.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span class=""><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
    El 17/08/16 a las 23:20, Charles escribió:<br>
<br>
        Anybody had any luck finding sample code that uses the 3.0 API<br>
        There was some traffic back in June that just seemed to end...<br>
        Thanks<br>
<br>
    AFAIK, the 3.0 API does not work.  That is codecpar (which works but<br>
    is missing some stuff for encoding) and av_send_packet(),etc. which<br>
    do not work at all.<br>
    I suggest you wait until ffplay/ffmpeg get translated to that new<br>
    api before you try it yourself.<br>
<br>
What is codecpar ? I have never heard of it.<br>
<br>
Gabriel.<br>
</blockquote>
<br></span>
Gonzalo, kinda figured that out so now just a bunch of warnings...<br>
<br>
Gabriel,<br>
<br>
@@libavformat/avformat.h+878<br>
    /**<br>
     * @deprecated use the codecpar struct instead<br>
     */<br>
    attribute_deprecated<br>
    AVCodecContext *codec;<br>
<br>
@@libavformat/avformat.h+1212<br>
    /*<br>
     * Codec parameters associated with this stream. Allocated and freed by<br>
     * libavformat in avformat_new_stream() and avformat_free_context()<br>
     * respectively.<br>
     *<br>
     * - demuxing: filled by libavformat on stream creation or in<br>
     *             avformat_find_stream_info()<br>
     * - muxing: filled by the caller before avformat_write_header()<br>
     */<br>
    AVCodecParameters *codecpar;<div class=""><div class="h5"><br>
<br>
<br>
______________________________<wbr>_________________<br>
Libav-user mailing list<br>
<a href="mailto:Libav-user@ffmpeg.org" target="_blank">Libav-user@ffmpeg.org</a><br>
<a href="http://ffmpeg.org/mailman/listinfo/libav-user" rel="noreferrer" target="_blank">http://ffmpeg.org/mailman/list<wbr>info/libav-user</a><br>
</div></div></blockquote></div><br><br><br></div><div class="gmail_extra">OK. Is it just a straight replacement, e.g:<br><br><br></div><div class="gmail_extra"> AVCodecContext *cc;<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">vdecoder=avcodec_find_decoder(cc->codec_id);<br>avcodec_open2(cc, vdecoder, NULL);<br><br>cdata->frame_width=cdata->width = cc->width;<br>cdata->frame_height=cdata->height = cc->height;<br><br></div><div class="gmail_extra">becomes:<br><br>AVCodecParameters *cp;<br><br>vdecoder=avcodec_find_decoder(cp->codec_id);<br>avcodec_open2(cp, vdecoder, NULL);<br><br>cdata->frame_width=cdata->width = cp->width;<br>cdata->frame_height=cdata->height = cp->height;<br><br><br></div><div class="gmail_extra">etc ?<br><br><br><br><br></div><div class="gmail_extra">also:<br>avformat_find_stream_info() returns an array of streams...so in the new version it returns an array of stream and corresponding array of codecpar ?<br><br><br></div><div class="gmail_extra">Regards,<br></div><div class="gmail_extra">Gabriel.<br><br><br><br></div><div class="gmail_extra"><br><br><br><br><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br><br></div></div>