Hello all: <br><br>I created a class FFMpegMgr and a method init(); inside init() I just put three ffmpeg api there:<br>avcodec_register_all();<br>avdevice_register_all();<br> av_register_all();<br><br>The source file ffmpegmgr.cpp look like this:<br>
<br> void FFMpegMgr::init() {<br> avcodec_register_all();<br> avdevice_register_all();<br> av_register_all();<br><br>}<br><br>Now I got a "undefined reference to avcodec_register_all" error.<br><br>if I put that body in the class declaration or add a "inline" keyword, that problem was gone and the compilation succeeded.<br>
<br>question is, do those three functions, which are C functions defined in avcodec.h, have to be used only in the inline functions in C++?<br><br>Sorry if it appear naive - I've been out of touch with C/C++ for a while.<br>
<br>Thanks!<br>Hai<br><br><br>