libvlc bluray subtitles

This forum is about all development around libVLC.
Adriana
New Cone
New Cone
Posts: 3
Joined: 09 May 2014 12:35

libvlc bluray subtitles

Postby Adriana » 09 May 2014 12:44

Hello,

I am developing a video player in .NET arround libvlc.
The version used is: libvlc 2.1.3 and VLC same version.

I encountered the problem of subtitle / audio tracks / video tracks retrieval from the media. For this purpose, I use the functions:

libvlc_video_get_spu_description and
libvlc_video_get_spu_count

I use them after the video started playing, when a chapter or a title is changed, but they always return the same result:
subs count = 1
subs list = "Disabled".

I see that VLC (main application) returns these values correctly over the same video.
Also, for DVD these functions work as expected.

My questions are:
Am I using the correct functions ?
If I should use other ones, which ones ?
Am I using them improperly ?

Adriana
New Cone
New Cone
Posts: 3
Joined: 09 May 2014 12:35

Re: libvlc bluray subtitles

Postby Adriana » 15 May 2014 11:47

Update:

Found that:
libvlc_audio_get_track_description
libvlc_video_get_track_description
libvlc_video_get_spu_description

don't return the same list of elements as vlc does, over the same media. They only return "Disabled". The count of the tracks is also 0.

These elements are needed to be able to later change these properties using:
libvlc_audio_set_track
libvlc_video_set_track
libvlc_video_set_spu

I was able to get hold of the list of media tracks using
libvlc_media_tracks_get
But the _set_ functions above don't work when passing them items from the list obtained with libvlc_media_tracks_get.

mangokm40
Cone that earned his stripes
Cone that earned his stripes
Posts: 130
Joined: 20 May 2010 20:00

Re: libvlc bluray subtitles

Postby mangokm40 » 15 May 2014 15:06

Just trying to understand...
You're saying that VLC shows multiple subtitles.
However, the linked-list returned by 'libvlc_video_get_spu_description()' has only one item whose 'psz_name' is 'Disabled' and whose
'p_next' is null ?

Adriana
New Cone
New Cone
Posts: 3
Joined: 09 May 2014 12:35

Re: libvlc bluray subtitles

Postby Adriana » 16 May 2014 09:31

yes, correct. That is what is happening.

Update: after reading about similar issues, I've found the cause of my problem and its solution.
The subtitles/audio/video were not loaded at the moment I was querying them (when media duration changed event is launched, media parsed = true).

The solution I adopted is reading them and loading them into the menu where I display them only when the menu is shown.

More info at:
https://trac.videolan.org/vlc/ticket/5035


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 11 guests