This might suppress some warnings (and very slightly reduce code size)
when assertions are disabled. Not that I particularly like to create
VLC-specific macros.
This is what the tests expect, and was the final status before the
merge of ABORT and DEAD input events.
In fact, libvlc_Stopped does not really correspond to anything: it has
no STOPPED_S equivalent in the input thread state. The only way to
reach it is to call libvlc_media_player_stop() explicitly.
Regardless, lets keep it for backward compatibility.
MediaListEndReached event should not be sent only when a new sub item tree is
added, otherwise it won't be sent if media doesn't have any sub items.
To fix this issue, send the MediaListEndReached event when preparse function
terminates (only if the media_list was created either by user or by sub items
callbacks).
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This function gets the active device identifier for the current
audio output, if there is one, and is the complementary function
to libvlc_audio_output_device_set().
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Extended version of libvlc_media_parse_async. It uses a flag to specify parse
options and returns an int for error handling.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Expose an event to libvlc users which allows them to get notified when a media
list reached the end. That is, when the media list is attached to a media
(subitems) that completed a parsing. Or when the media list is attached to a
media discovery that stopped.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Don't call libvlc_media_list_set_media from media since it causes
p_md->p_subitems to retain p_md while p_md is already retaining
p_md->p_subitems, therefore these 2 objects won't be releasable.
Add a new internal variable: p_internal_md that is set from media without
retaining it.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
This way, libvlc_media_subitems can be called before, during or after a
parsing. Furthermore, this allows to attach media_list events before
libvlc_media_parse is called.
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
A variable cannot be inherited if it is not a configuration item.
Note this only avoids generating an error; VBI cannot work without the
plugin anyway.
libvlc_media_discoverer_new_from_name was creating a services_discovery_t and
was starting it, so libvlc_MediaDiscovererStarted event (or any other events)
could not be received.
To fix that, Split libvlc_media_discoverer_new_from_name into
libvlc_media_discoverer_new and libvlc_media_discoverer_start. That way, we can
attach events between create and start.
libvlc_media_discoverer_new_from_name is now deprecated, but it still works
like before.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
Prevent the es_out from overriding the NowPlaying state by splitting
the meta into NowPlaying and ESNowPlaying.
The function input_item_GetNowPlayingFb can be used to return the
preferred meta value.
This ensures that subpictures blending works, and avoids copying back
video frames from GPU to CPU. For proper hardware acceleration,
use libvlc_media_player_set_xwindow() instead.
The "libvlc_MediaListPlayerPlayed" event was defined but unused.
It is now fired when libvlc_media_list_player is played until last item in the playlist
Signed-off-by: Igor Prokopenkov <cmyk777@gmail.com>
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
libvlc_media_player_set_video_title_display() was wrongly using the
enum value directly, leading to the video title appearing in the wrong
position for some values
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>