Query and select tracks
[Decoding of multimedia streams]


Functions

int bgav_num_tracks (bgav_t *bgav)
 Get the number of tracks.
const char * bgav_get_description (bgav_t *bgav)
 Get a technical description of the format.
gavl_time_t bgav_get_duration (bgav_t *bgav, int track)
 Get the duration of a track.
int bgav_num_audio_streams (bgav_t *bgav, int track)
 Get the number of audio streams of a track.
int bgav_num_video_streams (bgav_t *bgav, int track)
 Get the number of video streams of a track.
int bgav_num_subtitle_streams (bgav_t *bgav, int track)
 Get the number of subtitle streams of a track.
const char * bgav_get_track_name (bgav_t *bgav, int track)
 Get the name a track.
const bgav_metadata_tbgav_get_metadata (bgav_t *bgav, int track)
 Get metadata for a track.
int bgav_select_track (bgav_t *bgav, int track)
 Select a track.
int bgav_get_num_chapters (bgav_t *bgav, int track, int *timescale)
 Get the number of chapters.
const char * bgav_get_chapter_name (bgav_t *bgav, int track, int chapter)
 Get the name of a chapter.
int64_t bgav_get_chapter_time (bgav_t *bgav, int track, int chapter)
 Get the name of a chapter.

Detailed Description

Each opened decoder can have multiple tracks. You must select the track you wish to decode before you can do anything else.

Function Documentation

int bgav_num_tracks ( bgav_t bgav  ) 

Get the number of tracks.

Parameters:
bgav A decoder instance
Returns:
The number of tracks.

const char* bgav_get_description ( bgav_t bgav  ) 

Get a technical description of the format.

Parameters:
bgav A decoder instance
Returns:
Description

gavl_time_t bgav_get_duration ( bgav_t bgav,
int  track 
)

Get the duration of a track.

Parameters:
bgav A decoder instance
track Track index (starting with 0)
Returns:
The duration of a track or GAVL_TIME_UNDEFINED if the duration is not known.

int bgav_num_audio_streams ( bgav_t bgav,
int  track 
)

Get the number of audio streams of a track.

Parameters:
bgav A decoder instance
track Track index (starting with 0)
Returns:
The number of audio streams

int bgav_num_video_streams ( bgav_t bgav,
int  track 
)

Get the number of video streams of a track.

Parameters:
bgav A decoder instance
track Track index (starting with 0)
Returns:
The number of video streams

int bgav_num_subtitle_streams ( bgav_t bgav,
int  track 
)

Get the number of subtitle streams of a track.

Parameters:
bgav A decoder instance
track Track index (starting with 0)
Returns:
The number of subtitle streams

const char* bgav_get_track_name ( bgav_t bgav,
int  track 
)

Get the name a track.

Parameters:
bgav A decoder instance
track Track index (starting with 0)
Returns:
The track name if present or NULL.

const bgav_metadata_t* bgav_get_metadata ( bgav_t bgav,
int  track 
)

Get metadata for a track.

Parameters:
bgav A decoder instance
track Track index (starts with 0)
Returns:
A metadata container (see Metadata)

int bgav_select_track ( bgav_t bgav,
int  track 
)

Select a track.

Parameters:
bgav A decoder instance
track Track index (starts with 0)
Returns:
0 if there was no such track, 1 else
Select the track. All subsequent function calls will refer to the track you selected.

int bgav_get_num_chapters ( bgav_t bgav,
int  track,
int *  timescale 
)

Get the number of chapters.

Parameters:
bgav A decoder instance
track Track index (starts with 0)
timescale Returns the timescale of the seekpoints
Returns:
The number of chapters or 0 if the format doesn't support chapters
Chapters are simply named seekpoints. Use bgav_get_chapter_time and bgav_get_chapter_name to query the chapters.

const char* bgav_get_chapter_name ( bgav_t bgav,
int  track,
int  chapter 
)

Get the name of a chapter.

Parameters:
bgav A decoder instance
track Track index (starts with 0)
chapter Chapter index (starts with 0)
Returns:
The name of the chapter or NULL

int64_t bgav_get_chapter_time ( bgav_t bgav,
int  track,
int  chapter 
)

Get the name of a chapter.

Parameters:
bgav A decoder instance
track Track index (starts with 0)
chapter Chapter index (starts with 0)
Returns:
The time of the chapter


Generated on Sun Aug 3 15:34:52 2008 for gmerlin-avdecoder by  doxygen 1.5.6