MP4GetNumberOfTracks - Get the number of tracks
#include <mp4.h>
u_int32_t MP4GetNumberOfTracks(
MP4FileHandle hFile,
const char* type = NULL,
u_int8_t subType = 0
)
The number of tracks of the specified type and subType in the mp4 file.
MP4GetNumberOfTracks returns how many tracks of the specified type and subtype exist in the mp4 file. This can be used to determine if an mp4 file contains a track of a given type of media, for instance audio or video. It can also be used to determine if multiple options may be available. For instance multiple audio tracks in different languages.
For audio and video tracks, a subtype can be specified to only count tracks of a particular encoding.
MP4(3)