MP4(3)

NAME

MP4GetTrackDuration - Get the duration of a track

SYNTAX

#include <mp4.h>

MP4Duration MP4GetTrackDuration(
    MP4FileHandle hFile,
    MP4TrackId trackId
)

ARGUMENTS

hFile
    Specifies the mp4 file to which the operation applies.

trackId
    Specifies the track for which the duration is desired.

RETURN VALUES

The duration in track time scale units of the track in the mp4 file.

DESCRIPTION

MP4GetTrackDuration returns the total duration of all the samples in the specified track in the mp4 file.

Caveat: The value is in units of the track time scale.

SEE ALSO

MP4(3)