|Microsoft DirectX 9.0|
The ShouldDrawSampleNow method determines how a sample is scheduled for rendering.
virtual HRESULT ShouldDrawSampleNow( IMediaSample *pMediaSample, REFERENCE_TIME *pStartTime, REFERENCE_TIME *pEndTime );
Pointer to the sample's IMediaSample interface.
Pointer to a variable that contains the sample's start time.
Pointer to a variable that contains the sample's end time.
Returns S_FALSE. If the derived class overrides this method, return one of the values shown in the following table.
|S_OK||The sample should be rendered immediately.|
|S_FALSE||The sample should be scheduled for rendering, based on the time stamps.|
|Error code||Do not render this sample.|
The CBaseRenderer::GetSampleTimes method calls this method. By default, samples are always scheduled for rendering based on their time stamps. The derived class can override this method; for example, to implement quality control.