|
gavl
|
Chapter list. More...
Data Structures | |
| struct | gavl_chapter_list_t |
| Chapter list. More... | |
Functions | |
| GAVL_PUBLIC gavl_chapter_list_t * | gavl_chapter_list_create (int num_chapters) |
| Create chapter list. More... | |
| GAVL_PUBLIC gavl_chapter_list_t * | gavl_chapter_list_copy (const gavl_chapter_list_t *list) |
| Copy chapter list. More... | |
| GAVL_PUBLIC void | gavl_chapter_list_destroy (gavl_chapter_list_t *list) |
| Destroy chapter list. More... | |
| GAVL_PUBLIC void | gavl_chapter_list_insert (gavl_chapter_list_t *list, int index, int64_t time, const char *name) |
| Insert a chapter into a chapter list. More... | |
| GAVL_PUBLIC void | gavl_chapter_list_delete (gavl_chapter_list_t *list, int index) |
| Delete a chapter from a chapter list. More... | |
| GAVL_PUBLIC int | gavl_chapter_list_get_current (gavl_chapter_list_t *list, gavl_time_t time) |
| Get current chapter. More... | |
| GAVL_PUBLIC int | gavl_chapter_list_changed (gavl_chapter_list_t *list, gavl_time_t time, int *current_chapter) |
| Get current chapter. More... | |
| GAVL_PUBLIC void | gavl_chapter_list_dump (const gavl_chapter_list_t *list) |
| Dump a chapter list to stderr. More... | |
Chapter list.
Chapters in gavl are simply seekpoints with (optionally) associated names.
Since 1.5.0
| GAVL_PUBLIC gavl_chapter_list_t* gavl_chapter_list_create | ( | int | num_chapters | ) |
Create chapter list.
| num_chapters | Initial number of chapters |
| GAVL_PUBLIC gavl_chapter_list_t* gavl_chapter_list_copy | ( | const gavl_chapter_list_t * | list | ) |
Copy chapter list.
| list | Chapter list |
| GAVL_PUBLIC void gavl_chapter_list_destroy | ( | gavl_chapter_list_t * | list | ) |
Destroy chapter list.
| list | A chapter list |
| GAVL_PUBLIC void gavl_chapter_list_insert | ( | gavl_chapter_list_t * | list, |
| int | index, | ||
| int64_t | time, | ||
| const char * | name | ||
| ) |
Insert a chapter into a chapter list.
| list | A chapter list |
| index | Position (starting with 0) where the new chapter will be placed |
| time | Start time of the chapter |
| name | Chapter name (or NULL) |
| GAVL_PUBLIC void gavl_chapter_list_delete | ( | gavl_chapter_list_t * | list, |
| int | index | ||
| ) |
Delete a chapter from a chapter list.
| list | A chapter list |
| index | Position (starting with 0) of the chapter to delete |
| GAVL_PUBLIC int gavl_chapter_list_get_current | ( | gavl_chapter_list_t * | list, |
| gavl_time_t | time | ||
| ) |
Get current chapter.
| list | A chapter list |
| time | Playback time |
Use this function after seeking to signal a chapter change
| GAVL_PUBLIC int gavl_chapter_list_changed | ( | gavl_chapter_list_t * | list, |
| gavl_time_t | time, | ||
| int * | current_chapter | ||
| ) |
Get current chapter.
| list | A chapter list |
| time | Playback time |
| current_chapter | Returns the current chapter |
Use this function during linear playback to signal a chapter change
| GAVL_PUBLIC void gavl_chapter_list_dump | ( | const gavl_chapter_list_t * | list | ) |
Dump a chapter list to stderr.
| list | A chapter list |
Use this for debugging
1.8.6