Microsoft DirectX 9.0

IMediaSample::GetMediaTime

The GetMediaTime method retrieves the media times for this sample.

Syntax

HRESULT GetMediaTime(
  LONGLONG *pTimeStart,
  LONGLONG *pTimeEnd
);

Parameters

pTimeStart

[out] Pointer to a variable that receives the media start time.

pTimeEnd

[out] Pointer to a variable that receives the media stop time.

Return Value

Returns an HRESULT value. Possible values include those shown in the following table.

Value Description
S_OK Success.
VFW_E_MEDIA_TIME_NOT_SET Media times are not set on this sample.

Remarks

For more information about media times, see Time and Clocks in DirectShow.

See Also