With the Media SDK 2012, it really seems to me as though for most H.264 streaming video sources, it's not possible to, off the bat, decode one frame at a time, even when MFX_BITSTREAM_COMPLETE_FRAME flag is set and the AsyncDepth video param is set to 1.
After processing the header from a video stream, if I try to decode one I-Frame, then I get MFX_ERR_MORE_DATA.
The behavior I see if I let it advance the DataOffset value and modify the DataLength as it desires is that after it decodes the header, then it moves the DataOffset back to the beginning of the stream. When DecodeFrameAsync is called the first time, it skips (the DataOffset) past the header and IFrame in the bitstream and requests more surfaces (which is fine to request -- but why move the DataOffset amount and adjust the DataLength if it didn't decode because it needed more surfaces?). Then the next time DecodeFrameAsync is called (with sufficient surfaces available), it finally starts decoding -- the next frame, not the first one.
If I try to get it to decode an IFrame with no data after it, with sufficient surfaces, it gives MFX_ERR_MORE_DATA forever. It seems as though it has to have more than one frame in the bitstream for it to be willing to do any decoding.
Is it really not possible to decode individual frames, as is claimed, or am I likely missing something? Any idea what it might be?