IMultiMediaStream::GetTime

This method retrieves the current time from the multimedia stream's clock, if it has a clock.

HRESULT GetTime(
  STREAM_TIME* pCurrentTime
);

Parameters

  • pCurrentTime
    [out] Pointer to a STREAM_TIME value that will contain the current time, if the media stream has a clock.

Return Values

Returns one of the following values.

Value Description
E_POINTER The pCurrentTime pointer is invalid.
S_FALSE Stream does not have a clock; *pCurrentTime is zero.
S_OK Stream has a clock and the method succeeded; pCurrentTime contains the current time.

Remarks

If the stream does not have a clock, this method sets *pCurrentTime to zero and returns S_FALSE. If a stream has a clock, the stream sample times are relative to the stream's clock.

STREAM_TIME is defined as a LONGLONG value.

Requirements

DirectShow applications and DirectShow filters have different include file and link library requirements. See Setting Up the Build Environment for more information.

OS Versions: Windows CE 2.12 and later. Version 2.12 requires DXPAK 1.0 or later.

See Also

IMultiMediaStream Interface

Last updated on Wednesday, April 13, 2005

© 2005 Microsoft Corporation. All rights reserved.