IMFSample::SetSampleTime Method

Sets the presentation time of the sample.

Syntax

public:
HRESULT SetSampleTime(
         LONGLONG hnsSampleTime
)  

Parameters

hnsSampleTime
Type: LONGLONG 

The presentation time, in 100-nanosecond units.

Return value

Type: HRESULT 

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return codes
Return code Description
S_OK The method succeeded.

Refer to Media Foundation return codes.

Remarks

Some pipeline components require samples that have time stamps. Generally the component that generates the data for the sample also sets the time stamp. The Media Session might modify the time stamps.

Requirements

Header: Declared in mfobjects.h (include mfidl.h).

Library: Use mfuuid.lib.