locked
IMFSourceReader blocking

    General discussion

  • I was gonna add this to the documentation page on msdn, but it keeps coming up with error. So I decided to put it here just so people who run into this problem and searches will find it.

    Just addition to say that if MF_SOURCE_READERF_ERROR is given in the pdwStreamFlags variable, any extra calls to SourceReader's methods will block if using synchronous SourceReader. It can be caused by SourceReader's internal buffer being filled up, but there are also other reasons for the cause of MF_SOURCE_READERF_ERROR.

    To fix this I just reinitialised the SourceReader by creating a new SourceReader, then setting CurrentMediaType, and StreamSelection. Also make sure u set the currentPosition of the sourceReader to the previous position where MF_SOURCE_READERF_ERROR is given.

    Friday, July 12, 2013 12:25 AM