I've been using the MediaSDK for video conferencing (I work with VCon, an Israeli video conferencing company), and have encountered an oddity : When I start receiving the stream, I fill in the header-related structures using MFXVideoDECODE_DecodeHeader, per the documentation.
That works splendidly if all of the NAL's generated by the encoder are develivered. However, if the FIRST NAL is dropped (by network issues or in synthetic testing), the function returns -10 (which is reasonable, as data is missing) for a very long time, after which it starts returning -16 (a mostly undefined error), and NEVER locks on to the stream's parameters.
Dropping all of the NAL's (in my receiver code) until a NAL of type 7 is received, and then processing the received NAL's using MFXVideoDECODE_DecodeHeader in the exact same manner, everything works.
I was under the impression that as long as the packets starting from a certain position in the stream are fed into the function, it'll eventually lock on to the stream's parameters, was I mistaken ?
P.S. the stream in question is generated by MediaSDK's encoder, hardware mode. The easiest way to show it is to blot-out the 00 00 01 07, the first time it appears in the stream, and then you'll see that while other decoders (FFMPEG) do recognize the file, MediaSDK's MFXVideoDECODE_DecodeHeader never returns MFX_ERR_NONE...