Ok I have a serious question. I have compiled ffmpeg in mingw and am running in MS visual studio, I am getting an access violation reading in ffmpeg ff_msmpeg4_encode_block(). I am unable to see source code of ffmpeg unless there is a way to get msvs debugger compatible with gdb, I do not know much about this.
I might know what is causing the problem though. I have written my program in c++ and my first thought is I have two instances of an encoder both msmpeg4v3. They are completely different objects and I don't know if you are allowed to have two instances of an encoder encoding but it seems to work fine most of the time. My second thought is I have two AVFrames inPic and outPic and they are allocated in the constructor and deallocated in the destructor. This happens only once in the lifetime of the encoder object. So my thought is that maybe I should be allocating and deallocating every single encode, but this seems a little overboard to me that's why I did not do it like that. Here is my logic it is very simple. 1. create two encoder objects encA, encB. when they are created they will initialize parameters for the encoder and each allocate 2 AVFrames inPic and outPic. inPic and outPic are used in img_convert, outPic is used in avcodec_encode_video. 2. The two object will keep encoding and then sending the output of the encoder over TCP. It works for about maybe 4-5 hours and then crashes on access violation reading 0x0 in ff_msmpeg4_encode_block(). Call stack: ff_msmpeg4_encode_block() msmpeg4_encode_mb() MPV_encode_picture() MPV_encode_picture() Any one have any comments or suggestions? ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. _______________________________________________ libav-user mailing list [email protected] https://lists.mplayerhq.hu/mailman/listinfo/libav-user
