IMFPresentationClock interface (mfidl.h)

Represents a presentation clock, which is used to schedule when samples are rendered and to synchronize multiple streams.

Inheritance

The IMFPresentationClock interface inherits from IMFClock. IMFPresentationClock also has these types of members:

Methods

The IMFPresentationClock interface has these methods.

 
IMFPresentationClock::AddClockStateSink

Registers an object to be notified whenever the clock starts, stops, or pauses, or changes rate.
IMFPresentationClock::GetTime

Retrieves the latest clock time.
IMFPresentationClock::GetTimeSource

Retrieves the clock's presentation time source.
IMFPresentationClock::Pause

Pauses the presentation clock. While the clock is paused, the clock time does not advance, and the clock's IMFPresentationClock::GetTime returns the time at which the clock was paused.
IMFPresentationClock::RemoveClockStateSink

Unregisters an object that is receiving state-change notifications from the clock.
IMFPresentationClock::SetTimeSource

Sets the time source for the presentation clock. The time source is the object that drives the clock by providing the current time.
IMFPresentationClock::Start

Starts the presentation clock.
IMFPresentationClock::Stop

Stops the presentation clock. While the clock is stopped, the clock time does not advance, and the clock's IMFPresentationClock::GetTime method returns zero.

Remarks

To create a new instance of the presentation clock, call the MFCreatePresentationClock function. The presentation clock must have a time source, which is an object that provides the clock times. For example, the audio renderer is a time source that uses the sound card to drive the clock. Time sources expose the IMFPresentationTimeSource interface. To set the time source, call SetTimeSource. The presentation clock does not begin running until the Start method is called.

To get the presentation clock from the Media Session, call IMFMediaSession::GetClock.

Requirements

   
Minimum supported client Windows Vista [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 [desktop apps | UWP apps]
Target Platform Windows
Header mfidl.h

See also

IMFClock

Media Foundation Interfaces

Presentation Clock