<div class="gmail_quote">On Fri, Sep 23, 2011 at 1:58 AM, Marlon Reid <span dir="ltr"><<a href="mailto:Marlon@scansoft.co.za">Marlon@scansoft.co.za</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<u></u>
<div>
<div dir="ltr" align="left"><span><font color="#005080" face="Trebuchet MS">Hi Matt,</font></span></div>
<div dir="ltr" align="left"><span><font color="#005080" face="Trebuchet MS"></font></span> </div>
<div dir="ltr" align="left"><span><font color="#005080" face="Trebuchet MS">Thanks for your response. Yes I did call
av_register_all();. I also used my C extern braces around
<avcodec.h> and <avformat.h>.</font></span></div>
<div dir="ltr" align="left"><span><font color="#005080" size="2" face="Trebuchet MS"></font></span> </div>
<div dir="ltr" align="left"><span><font color="#005080" size="2" face="Trebuchet MS">What does avcodec_register_all() do? Should
this be called as well?</font></span></div>
<div dir="ltr" align="left"><span><font color="#005080" size="2" face="Trebuchet MS"></font></span> </div><br></div></blockquote></div><br>av_register calls avcodec_register so you don't have to call it. The av_register functions registers the codec etc so that you can use it.<br>
<br>I don't know why you're having trouble. I ran the following code in MSVC++ 2010 using the Zeranoe built dlls without any trouble. Where did you get the dlls that you're using, did you compile it? Can you run just the following code and see if you still get an error? Btw, I ran it in debug 64 bit project.<br>
<br>av_register_all();<br>AVOutputFormat* m_Outfmt = av_guess_format ( "mp3", NULL, NULL);<br>if( !m_Outfmt )<br> return false;<br>AVFormatContext* m_OutFmtContext = avformat_alloc_context ();<br><br>Matt<br>
<span></span>