Question

I'm getting an E_POINTER error from the ReadSample call, and as far as I can tell, none of the pointers are invalid. See snippet below (note, it's a C++/CLI app):

IMFSample* sample = NULL;
pin_ptr<IMFSample*> pinnedSample = &sample;

LONGLONG timeStamp;

HRESULT hr = mSourceReader->ReadSample(
    (DWORD)MF_SOURCE_READER_FIRST_VIDEO_STREAM,
    0,
    NULL,
    NULL,
    &timeStamp,
    pinnedSample
    );

I suspect the problem lies in the construction of the mSourceReader (an IMFSourceReader instance, created from an IMFMediaSource). But, alas, I've no idea how to backtrack and find the source, as all the COM calls in the chain of commands that created mSourceReader returned S_OK.

Much thanks for any tips.

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top