Windows Media Format SDK banner art
PreviousNext

IWMReaderCallbackAdvanced::OnTime

The OnTime method notifies the application of the clock time the reader is working to. This is used when a user-driven clock has been specified.

Syntax

HRESULT OnTime(
  QWORD  cnsCurrentTime,
  void*  pvContext
);

Parameters

  cnsCurrentTime

[in]  QWORD containing the current time in 100-nanosecond units.

  pvContext

[in]  Universal pointer to the context.  This context matches the context from IWMReader::Start.

Return Values

If the method succeeds, it returns S_OK. If it fails, it returns an HRESULT error code.

Remarks

There are two cases in which callbacks indicating what the reader registers as the current elapsed time should be received by an application. The first case occurs when there are gaps in a Windows Media file (for example, no audio for 10 seconds). The OnTime call continues to be called, while OnSample does not. In the second case, if the application is driving the clock, the reader must communicate its own time to the application to prevent the application from overrunning the reader.

See Also

PreviousNext


© 1999 Microsoft Corporation. All rights reserved.