Microsoft DirectX 9.0

IStreamSample Interface

The IStreamSample interface provides control over the behavior of stream samples. You can retrieve the media stream that created the sample, set or retrieve sample start and stop times, check the sample's completion status, and perform a developer-specified function on the sample itself.

Implement this interface when you implement a media stream for a new media type. The interface is exposed on sample objects created by media streams.

Use this interface when you want to control data samples created by IMediaStream or its derived interfaces.

In addition to the methods inherited from IUnknown, the IStreamSample interface exposes the following methods.

Method Description
CompletionStatus Retrieves the status of the current sample's latest asynchronous update. If the update isn't complete, you can force it to complete.
GetMediaStream Retrieves a pointer to the media stream object that created the current sample.
GetSampleTimes Retrieves the current sample's start and end times.
SetSampleTimes Sets the current sample's start and end times.
Update Performs a synchronous or an asynchronous update on the current sample.