IMFStreamSink::ProcessSample method (mfidl.h)
Delivers a sample to the stream. The media sink processes the sample.
Syntax
HRESULT ProcessSample(
[in] IMFSample *pSample
);
Parameters
[in] pSample
Pointer to the IMFSample interface of a sample that contains valid data for the stream.
Return value
The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.
Return code | Description |
---|---|
|
The method succeeded. |
|
The media sink is in the wrong state to receive a sample. For example, preroll is complete but the presentation clock has not started yet. |
|
The sample has an invalid time stamp. See Remarks. |
|
The media sink is paused or stopped and cannot process the sample. |
|
The presentation clock was not set. Call IMFMediaSink::SetPresentationClock. |
|
The sample does not have a time stamp. |
|
The stream sink has not been initialized. |
|
The media sink's Shutdown method has been called. |
|
This stream was removed from the media sink and is no longer valid. |
Remarks
Call this method when the stream sink sends an MEStreamSinkRequestSample event.
This method can return MF_E_INVALID_TIMESTAMP for various reasons, depending on the implementation of the media sink:
- Negative time stamps.
- Time stamps that jump backward (within the same stream).
- The time stamps for one stream have drifted too far from the time stamps on another stream within the same media sink (for example, an archive sink that multiplexes the streams).
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2008 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | mfidl.h |
Library | Mfuuid.lib |