Hello,

I have compiled "ffmpeg\libavcodec\apiexample.c" file using MSVC 8.0 (The 
project is attached). 
On running, it returns error from code (Please look for "ERROR RETURNED HERE"):

//--------------------------------------------------------
void audio_decode_example(const char *outfilename, const char *filename)
{
...
        while (size > 0) {
            len = pWrap->avcodec_decode_audio2(c, (short *)outbuf, &out_size, 
inbuf_ptr, size);
            if (len < 0) {

                ERROR RETURNED HERE ---> fprintf(stderr, "Error while 
decoding\n");

                exit(1);
            }
...
} // end  void audio_decode_example(const char *outfilename, const char 
*filename)
//--------------------------------------------------------

The above function was called from main() (Please look for "FUNCTION CALLED 
HERE")
//--------------------------------------------------------
main() {
...
    if (argc <= 1) {
        audio_encode_example("c:\\temp\\test.mp2");

        FUNCTION CALLED HERE --->audio_decode_example("c:\\temp\\test.sw", 
"c:\\temp\\test.mp2");

        video_encode_example("c:\\temp\\test.mpg");
        filename = "c:\\temp\\test.mpg";
    } else {
...
} // end main

//--------------------------------------------------------


I need to know why this may be happening and if possible, what can I do to 
solve this. My installation & configuration details are as follows:

I ahve built ffmeg dll files using MingW & MSys. My PC runs on WinXP SP2 OS. 

SVN URL: svn://svn.ffmpeg.org/ffmpeg/trunk


Output DLL Files:
avcodec-52.10.0.dll (avcodec.dll)
avutil-49.12.0.dll (avutil.dll)
(and there are others, but i think they not worth mentioning here.)


Commands used for build:
./configure --extra-cflags="-mno-cygwin -mms-bitfields" --extra-ldflags="-Wl 
-add-stdcall-alias" --target-os=mingw32 --enable-static --enable-shared 
--enable-memalign-hack
make
make install


My MingW installer's ini file's current section looks like Following:
[current]
runtime=mingwrt-3.15.1-mingw32.tar.gz|560294
w32api=w32api-3.12-mingw32-dev.tar.gz|14500
runtime-dev=mingwrt-3.15.1-mingw32-dev.tar.gz|552522
runtime-dll=mingwrt-3.15.1-mingw32-dll.tar.gz|6903
binutils=binutils-2.17.50-20060824-1.tar.gz|21940
core=gcc-core-3.4.5-20060117-3.tar.gz|7712
gpp=gcc-g++-3.4.5-20060117-3.tar.gz|15480
g77=gcc-g77-3.4.5-20060117-3.tar.gz|5272
ada=gcc-ada-3.4.5-20060117-3.tar.gz|33860
java=gcc-java-3.4.5-20060117-3.tar.gz|43160
objc=gcc-objc-3.4.5-20060117-3.tar.gz|3720
make=mingw32-make-3.81-20080326-2.tar.gz|727

With MSYS I have installed:
1. bash-2.05b-MSYS.tar.bz2
2. coreutils-5.97-MSYS-1.0.11-snapshot.tar.bz2
3. make-3.81-MSYS-1.0.11-2.tar.bz2.


That's all !

Thank you.

Best Regards,
Rupesh Bhurke

Attachment: SampleConsolApp_01_2009_01_14_1409.rar
Description: Binary data

_______________________________________________
libav-user mailing list
[email protected]
https://lists.mplayerhq.hu/mailman/listinfo/libav-user

Reply via email to