Selecting audio and subtitle streams

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
hippojay Offline
Fan
Posts: 301
Joined: Mar 2008
Reputation: 13
Location: Sheffield, UK
Post: #1
Guys,

Is there anyway to select the particular audio or subtitle stream in a file (if they exist). I'd like to be able to activate subtitles (and/or audio) based on a locally set variable, but don't see anyway to modify the selected streams...

If not (and you think it's an okay idea) i'll open up a trac..

(Just to clarify, I'm not looking for XBMC to list the streams as well, just to be able to play a certain one like xbmc.player().setAudioStream(id) )
find quote
hippojay Offline
Fan
Posts: 301
Joined: Mar 2008
Reputation: 13
Location: Sheffield, UK
Post: #2
No way to do it?

I guess that the code exists (as skin audio odd settings can see and manipulate) but that the interface with python does not?
find quote
hippojay Offline
Fan
Posts: 301
Joined: Mar 2008
Reputation: 13
Location: Sheffield, UK
Post: #3
In the end I had to go scrabbling through the source code to see if anything was available Sad and I see that some new functions were added this year for Eden..

xbmc.Player().getAvailableAudioStreams() - returns a list. Use index number to set audio
xbmc.Player().setAudioStream(int)

You'll need a pre-11, but hopefully this might help someone else..

As for Subtitles - i'm using some bizarro workarounds,. Get subttitles and cycling through until the name matches the region I want to display them for.. Urghhhh
find quote