libgpac
Documentation of the core library of GPAC
|
Data Structures | |
struct | s_accumulated_attributes |
struct | HLS_LLChunk |
Macros | |
#define | _GNU_SOURCE |
#define | GROUP_ID_TO_PROGRAM_ID(type, group_id) |
#define | M3U8_COMPATIBILITY_VERSION(v) |
#define | M3U8_BUF_SIZE 2048 |
#define | RST_ATTR(_name) if (attribs->_name) { gf_free(attribs->_name); attribs->_name = NULL; } |
#define | _CLEANUP |
Functions | |
GF_Err | playlist_element_del (PlaylistElement *e) |
static GF_Err | cleanup_list_of_elements (GF_List *list) |
static PlaylistElement * | playlist_element_new (PlaylistElementType element_type, const char *url, s_accumulated_attributes *attribs) |
static Stream * | stream_new (int stream_id) |
static GF_Err | stream_del (Stream *stream) |
static GFINLINE int | string2num (const char *s) |
static Bool | safe_start_equals (const char *attribute, const char *line) |
static void | reset_attributes (s_accumulated_attributes *attributes) |
static char ** | extract_attributes (const char *name, const char *line, const int num_attributes) |
static void | free_attrs (char **attributes) |
static char ** | parse_attributes (const char *line, s_accumulated_attributes *attributes) |
MasterPlaylist * | master_playlist_new () |
GF_Err | gf_m3u8_master_playlist_del (MasterPlaylist **playlist) |
static Stream * | master_playlist_find_matching_stream (const MasterPlaylist *pl, const u32 stream_id) |
GF_EXPORT GF_Err | gf_m3u8_parse_master_playlist (const char *file, MasterPlaylist **playlist, const char *baseURL) |
GF_Err | declare_sub_playlist (char *currentLine, const char *baseURL, s_accumulated_attributes *attribs, PlaylistElement *sub_playlist, MasterPlaylist **playlist, Stream *in_stream) |
static void | reset_attribs (s_accumulated_attributes *attribs, Bool is_cleanup) |
GF_Err | gf_m3u8_parse_sub_playlist (const char *m3u8_file, MasterPlaylist **playlist, const char *baseURL, Stream *in_stream, PlaylistElement *sub_playlist, Bool is_master) |
struct s_accumulated_attributes |
Data Fields | ||
---|---|---|
char * | title | |
char * | mediaURL | |
double | duration_in_seconds | |
int | bandwidth | |
int | width | |
int | height | |
int | stream_id | |
char * | codecs | |
char * | language | |
char * | name | |
u32 | channels | |
MediaType | type | |
char * | group_audio | |
char * | group_video | |
char * | group_subtitle | |
char * | group_closed_captions | |
Bool | forced | |
int | target_duration_in_seconds | |
int | min_media_sequence | |
int | current_media_seq | |
u32 | version | |
u32 | compatibility_version | |
Bool | is_master_playlist | |
Bool | is_media_segment | |
Bool | is_playlist_ended | |
Bool | is_default | |
Bool | is_autoselect | |
u64 | playlist_utc_timestamp | |
u64 | byte_range_start | |
u64 | byte_range_end | |
u64 | init_byte_range_start | |
u64 | init_byte_range_end | |
PlaylistElementDRMMethod | key_method | |
char * | init_url | |
char * | key_url | |
bin128 | key_iv | |
Bool | has_iv | |
Bool | independent_segments | |
Bool | low_latency | |
Bool | independent_part | |
u32 | discontinuity |
#define _GNU_SOURCE |
#define GROUP_ID_TO_PROGRAM_ID | ( | type, | |
group_id | |||
) |
#define M3U8_COMPATIBILITY_VERSION | ( | v | ) |
#define M3U8_BUF_SIZE 2048 |
#define RST_ATTR | ( | _name | ) | if (attribs->_name) { gf_free(attribs->_name); attribs->_name = NULL; } |
#define _CLEANUP |
GF_Err playlist_element_del | ( | PlaylistElement * | e | ) |
Deletes an Playlist element
|
static |
|
static |
Creates an Playlist element. This element can be either a playlist of a stream according to first parameter.
|
static |
Creates a new stream properly initialized
|
static |
Deletes the specified stream
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Parses the attributes and accumulate into the attributes structure
MasterPlaylist* master_playlist_new | ( | ) |
Creates a new MasterPlaylist
GF_Err gf_m3u8_master_playlist_del | ( | MasterPlaylist ** | playlist | ) |
Deletes the given MasterPlaylist and all of its sub elements
|
static |
GF_EXPORT GF_Err gf_m3u8_parse_master_playlist | ( | const char * | file, |
MasterPlaylist ** | playlist, | ||
const char * | baseURL | ||
) |
Parse the given m3u8 playlist file
file | The file from cache to parse |
playlist | The playlist to fill. If argument is null, and file is valid, playlist will be allocated |
baseURL | The base URL of the playlist |
GF_Err declare_sub_playlist | ( | char * | currentLine, |
const char * | baseURL, | ||
s_accumulated_attributes * | attribs, | ||
PlaylistElement * | sub_playlist, | ||
MasterPlaylist ** | playlist, | ||
Stream * | in_stream | ||
) |
|
static |
GF_Err gf_m3u8_parse_sub_playlist | ( | const char * | file, |
MasterPlaylist ** | playlist, | ||
const char * | baseURL, | ||
Stream * | in_program, | ||
PlaylistElement * | sub_playlist, | ||
Bool | is_master | ||
) |
Parse the given playlist file as a subplaylist of an existing playlist
file | The file from cache to parse |
playlist | The playlist to fill. |
baseURL | base URL of the playlist |
in_program | in which the playlist is parsed |
sub_playlist | existing subplaylist element in the playlist in which the playlist is parsed |
is_master | set to true to indicate if this is the root playlist |