IMFStreamSink::Flush method

Causes the stream sink to drop any samples that it has received and has not rendered yet.

Syntax


HRESULT Flush();

Parameters

This method has no parameters.

Return value

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return codeDescription
S_OK

The method succeeded.

MF_E_NOT_INITIALIZED

The stream sink has not been initialized yet. You might need to set a media type.

MF_E_SHUTDOWN

The media sink's Shutdown method has been called.

MF_E_STREAMSINK_REMOVED

This stream was removed from the media sink and is no longer valid.

 

Remarks

If any samples are still queued from previous calls to the IMFStreamSink::ProcessSample method, the media sink immediately discards them, without processing them. This can cause a glitch in the rendered output. The running state of the sink (running, paused, or stopped) does not change.

Any pending marker events from the IMFStreamSink::PlaceMarker method are dispatched immediately, with the status code E_ABORT.

This method is synchronous. It does not return until the sink has discarded all pending samples.

Requirements

Minimum supported client

Windows Vista [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2008 [desktop apps | Windows Store apps]

Header

Mfidl.h

Library

Mfuuid.lib

See also

IMFStreamSink
Media Sinks

 

 

Community Additions

ADD
Show:
© 2014 Microsoft