IDvdInfo2::GetTotalTitleTime method (strmif.h)

[The feature associated with this page, DirectShow, is a legacy feature. It has been superseded by MediaPlayer, IMFMediaEngine, and Audio/Video Capture in Media Foundation. Those features have been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer, IMFMediaEngine and Audio/Video Capture in Media Foundation instead of DirectShow, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

The GetTotalTitleTime method retrieves the total playback time for the current title.

Syntax

HRESULT GetTotalTitleTime(
  [out] DVD_HMSF_TIMECODE *pTotalTime,
  [out] ULONG             *ulTimeCodeFlags
);

Parameters

[out] pTotalTime

Pointer to a DVD_HMSF_TIMECODE structure that receives the total time in hours, minutes, seconds, and frames.

[out] ulTimeCodeFlags

Receives a DVD_TIMECODE_FLAGS value indicating the frame rate at which the disc was authored to play. Specify NULL if you don't want to receive the timecode information.

Return value

Returns one of the following HRESULT values.

Return code Description
S_OK
Success.
E_POINTER
Invalid argument.
VFW_E_DVD_INVALIDDOMAIN
The DVD Navigator is not in the title domain.
VFW_S_DVD_NON_ONE_SEQUENTIAL
The title is not a one sequential video title, so the timing information might not be continuous.

Remarks

The total title time is the time required to play the title sequentially, not counting any stills, pauses, and so on.

This method is for use only with one sequential video titles, which are titles such as movies in which each chapter automatically branches to the next chapter so that the entire title plays continuously without stopping. Nonsequential video titles are titles whose chapters do not automatically play one after another. Because of variations in how DVD authors encode time information on nonsequential video titles, do not use this method to determine the total time for such titles.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header strmif.h (include Dshow.h)
Library Strmiids.lib

See also

DVD Applications

Error and Success Codes

IDvdInfo2 Interface