I've buit a small transcoder (in C++), not big deal, using Intel's filters mpeg2 decoder -> h264 encoder (from TS files). The SDK version is 1.5 Gold.
It works very nicely for quite some long time, but randomly, I keep getting this error (in Debug mode).
File: c:\\Program Files (x86)\\Microsoft Visual Studio 9.0\\VC\\include\\list
Expression: list iterator not dereferencable
When I dump the stack frame, here is what I get (calling orderd is from bottom up):
msvcp90d.dll!_Debug_message(const wchar_t * message=0x0000000180067be0, const wchar_t *file=0x0000000180067310, unsigned int line=218) Line 24
h264_enc_filter.dll!CBaseEncoder::DeliverNextFrame(void * pvParam=0x000000000046d770)
msvcr90d.dll!_callthreadstartex() Line 348 + 0x17 bytes
msvcr90d.dll!_threadstartex(void * ptd=0x000000000e448cd0) Line 331
I'm pretty sure, the problem is in the base_encoder.cpp, at:
it = pEncoder->m_ResList.begin(); <- HERE SEEMS TO BE THE PROBLEM
sts = pEncoder->m_mfxVideoSession.SyncOperation(*it->psyncP, 0);
if ((MFX_ERR_NONE != sts && MFX_WRN_IN_EXECUTION != sts && MFX_ERR_MORE_DATA != sts)|| pEncoder->m_bStop)
I'm running Debug mode, x64 or x32, with or without using shared MFC dlls. All the system consists of nothing more than instantiating the Intel's filters, and launch the graph. All filters work in sync mode. Tried to remove the sync clock from each of them, but the problem still occurs. Like I've said, it works nicely for some time (sometimes minutes, sometimes hours) with correct h264 output, and then suddenly crashes.
Is there are a problem with the output management in the h264 encoder? The output port is hooked to a standard file writer filter
My PC configuration: Win7 Home Edition, x64, Intel Core Duo P8700 2.53GHz, ATI
Any help would be highly appreciated.