VLC 4.0.0-dev
|
A LibVLC media list holds multiple libvlc_media_t media descriptors. More...
Files | |
file | libvlc_media_list.h |
LibVLC media list (playlist) external API. | |
Typedefs | |
typedef struct libvlc_media_list_t | libvlc_media_list_t |
Functions | |
LIBVLC_API libvlc_media_list_t * | libvlc_media_list_new (void) |
Create an empty media list. More... | |
LIBVLC_API void | libvlc_media_list_release (libvlc_media_list_t *p_ml) |
Release media list created with libvlc_media_list_new(). More... | |
LIBVLC_API libvlc_media_list_t * | libvlc_media_list_retain (libvlc_media_list_t *p_ml) |
Retain reference to a media list. More... | |
LIBVLC_API void | libvlc_media_list_set_media (libvlc_media_list_t *p_ml, libvlc_media_t *p_md) |
Associate media instance with this media list instance. More... | |
LIBVLC_API libvlc_media_t * | libvlc_media_list_media (libvlc_media_list_t *p_ml) |
Get media instance from this media list instance. More... | |
LIBVLC_API int | libvlc_media_list_add_media (libvlc_media_list_t *p_ml, libvlc_media_t *p_md) |
Add media instance to media list The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API int | libvlc_media_list_insert_media (libvlc_media_list_t *p_ml, libvlc_media_t *p_md, int i_pos) |
Insert media instance in media list on a position The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API int | libvlc_media_list_remove_index (libvlc_media_list_t *p_ml, int i_pos) |
Remove media instance from media list on a position The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API int | libvlc_media_list_count (libvlc_media_list_t *p_ml) |
Get count on media list items The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API libvlc_media_t * | libvlc_media_list_item_at_index (libvlc_media_list_t *p_ml, int i_pos) |
List media instance in media list at a position The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API int | libvlc_media_list_index_of_item (libvlc_media_list_t *p_ml, libvlc_media_t *p_md) |
Find index position of List media instance in media list. More... | |
LIBVLC_API bool | libvlc_media_list_is_readonly (libvlc_media_list_t *p_ml) |
This indicates if this media list is read-only from a user point of view. More... | |
LIBVLC_API void | libvlc_media_list_lock (libvlc_media_list_t *p_ml) |
Get lock on media list items. More... | |
LIBVLC_API void | libvlc_media_list_unlock (libvlc_media_list_t *p_ml) |
Release lock on media list items The libvlc_media_list_lock should be held upon entering this function. More... | |
LIBVLC_API libvlc_event_manager_t * | libvlc_media_list_event_manager (libvlc_media_list_t *p_ml) |
Get libvlc_event_manager from this media list instance. More... | |
A LibVLC media list holds multiple libvlc_media_t media descriptors.
typedef struct libvlc_media_list_t libvlc_media_list_t |
LIBVLC_API int libvlc_media_list_add_media | ( | libvlc_media_list_t * | p_ml, |
libvlc_media_t * | p_md | ||
) |
Add media instance to media list The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
p_md | a media instance |
LIBVLC_API int libvlc_media_list_count | ( | libvlc_media_list_t * | p_ml | ) |
Get count on media list items The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
LIBVLC_API libvlc_event_manager_t * libvlc_media_list_event_manager | ( | libvlc_media_list_t * | p_ml | ) |
Get libvlc_event_manager from this media list instance.
The p_event_manager is immutable, so you don't have to hold the lock
p_ml | a media list instance |
LIBVLC_API int libvlc_media_list_index_of_item | ( | libvlc_media_list_t * | p_ml, |
libvlc_media_t * | p_md | ||
) |
Find index position of List media instance in media list.
Warning: the function will return the first matched position. The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
p_md | media instance |
LIBVLC_API int libvlc_media_list_insert_media | ( | libvlc_media_list_t * | p_ml, |
libvlc_media_t * | p_md, | ||
int | i_pos | ||
) |
Insert media instance in media list on a position The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
p_md | a media instance |
i_pos | position in array where to insert |
LIBVLC_API bool libvlc_media_list_is_readonly | ( | libvlc_media_list_t * | p_ml | ) |
This indicates if this media list is read-only from a user point of view.
p_ml | media list instance |
true | read-only |
false | read/write |
LIBVLC_API libvlc_media_t * libvlc_media_list_item_at_index | ( | libvlc_media_list_t * | p_ml, |
int | i_pos | ||
) |
List media instance in media list at a position The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
i_pos | position in array where to insert |
LIBVLC_API void libvlc_media_list_lock | ( | libvlc_media_list_t * | p_ml | ) |
Get lock on media list items.
p_ml | a media list instance |
LIBVLC_API libvlc_media_t * libvlc_media_list_media | ( | libvlc_media_list_t * | p_ml | ) |
Get media instance from this media list instance.
This action will increase the refcount on the media instance. The libvlc_media_list_lock should NOT be held upon entering this function.
p_ml | a media list instance |
LIBVLC_API libvlc_media_list_t * libvlc_media_list_new | ( | void | ) |
Create an empty media list.
LIBVLC_API void libvlc_media_list_release | ( | libvlc_media_list_t * | p_ml | ) |
Release media list created with libvlc_media_list_new().
p_ml | a media list created with libvlc_media_list_new() |
LIBVLC_API int libvlc_media_list_remove_index | ( | libvlc_media_list_t * | p_ml, |
int | i_pos | ||
) |
Remove media instance from media list on a position The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |
i_pos | position in array where to insert |
LIBVLC_API libvlc_media_list_t * libvlc_media_list_retain | ( | libvlc_media_list_t * | p_ml | ) |
Retain reference to a media list.
p_ml | a media list created with libvlc_media_list_new() |
LIBVLC_API void libvlc_media_list_set_media | ( | libvlc_media_list_t * | p_ml, |
libvlc_media_t * | p_md | ||
) |
Associate media instance with this media list instance.
If another media instance was present it will be released. The libvlc_media_list_lock should NOT be held upon entering this function.
p_ml | a media list instance |
p_md | media instance to add |
LIBVLC_API void libvlc_media_list_unlock | ( | libvlc_media_list_t * | p_ml | ) |
Release lock on media list items The libvlc_media_list_lock should be held upon entering this function.
p_ml | a media list instance |