Page 1 of 1
track_description help / bug?
Posted: 22 Jul 2009 07:53
by Kairos
I'm implementing the track descriptions into my wrapper. I'm planing on caching the descriptions whenever possible. To do that I need to know, can the tracks change? See this is what I was thinking, if you change to a different title, then all the video/audio/subtitle/chapter tracks change. Is this true, and if so do the tracks only change when the title changes?
Re: track_description help
Posted: 22 Jul 2009 09:07
by Kairos
I've also noticed and inconsistency. libvlc_video_get_track_description returns 2 tracks,
-1 : Disabled
0 : Track_1
libvlc_video_get_track returns 1. This errors out in my code because no track with ID=1 exists. Track_1 should have an ID of 1, not 0.
Re: track_description help
Posted: 22 Jul 2009 09:24
by Jean-Baptiste Kempf
Arrays in C start at 0, which is why.
0 is the first element
Re: track_description help
Posted: 22 Jul 2009 09:36
by Kairos
Well the audio returns 1, not 0
libvlc_audio_get_track_description returns 2 tracks,
-1 : Disabled
1 : Track_1
libvlc_audio_get_track returns 1.