Microsoft DirectX 9.0 |
The Run method runs the filter.
Syntax
HRESULT Run(
REFERENCE_TIME tStart
);
Parameters
tStart
Reference time corresponding to
Return Value
Returns an HRESULT value. Possible values include those shown in the following table.
Value | Description |
S_FALSE | Transition is not complete. |
S_OK | Success. Transition is complete. |
Remarks
When a filter is running, it can receive, process, and deliver samples. Source filters generate new samples, and renderer filters render them.
The state transition might be asynchronous. If the method returns before the transition completes, the return value is S_FALSE.
Stream time is calculated as the current reference time minus tStart. To calculate when a media sample should be rendered, the renderer compares the time stamp with the current stream time. Thus, a media sample with a time stamp of zero should be rendered at time tStart. For more information, see Time and Clocks in DirectShow.
When an application calls the IMediaControl::Run method, the Filter Graph Manager calls IMediaFilter::Run on each filter. It sets the value of tStart slightly in the future, to account for graph latency.
See Also