Posts: 136
Joined: Nov 2012
not sure if it works for xvid as I havent used xvid for years, but you could map a key to switch audio,
Add a key with some custom action to the keyboard section of keymap.xml, and refer to it.
<keymap>
<global>
<keyboard>
<k>audionextlanguage</k>
</keyboard>
</global>
</keymap>
to have your XBMC switch audio track upon pressing the "k" key, and then add a corresponding button to the remote.
Posts: 118
Joined: Oct 2008
Reputation:
1
tvont
Senior Member
Posts: 118
2012-12-02, 10:59
(This post was last modified: 2012-12-02, 11:01 by tvont.)
Thanks for the hint. I forgot to mention that I use ATV2 :/, so I don't have keys beside the ones on the remote. Is it also possible with such a simplified remote? Ie. a key-combination of some of the 7 available? Or maybe with a setting in advancedsettings.xml?
Also, if someone is willing to tell me where this setting is in the source code - I could try to alter this and compile it by my own.
Posts: 31,445
Joined: Jan 2011
Frodo will let you define default audio and subtitle languages in
Settings/Appearance/International (wiki).
Posts: 7,135
Joined: Oct 2012
un1versal
Out of Memory (1939–2016)
Posts: 7,135
IIRC both Audio and Video streams can have language code attached including and not limited to .avi in fact opening a .avi with AVI mux GUI and pressing generate data source from files gives you pretty much the defined language code (if whoever encoded it defined a language code to begin with. If not it can be set and remuxed using one of the million tools available.
e.g.
Also not all MKV have language code defined for audio or video streams either, depends on who did the encoding and certainly can be easily fixed.
Which brings up a whole different issue, if your files dont have a language code
look at setting them and remuxing them or find an alternative way to solve a problem which is not in any way a XBMC limitation.
uNi
Posts: 118
Joined: Oct 2008
Reputation:
1
tvont
Senior Member
Posts: 118
Thanks, anyway. I know that I can set the language code. But for that loads of episodes - this is work where I will never find the time for. Unless there is a bulk editing tool, this is simply not feasible.
I never said that this is a limitation in XBMC, my question was: how can I set the audiostream to be '2' for default. There is a setting in the dialog where you can change the stream to '2' and also a 'save as default' - which has no effect for the audio stream even if it leads to the impression that you can set the default audio stream to '2'. At this point this is at least misleading.
TvT
Posts: 7,135
Joined: Oct 2012
un1versal
Out of Memory (1939–2016)
Posts: 7,135
2012-12-04, 21:59
(This post was last modified: 2012-12-04, 22:00 by un1versal.)
You can select the 2nd audio stream, but you cant set it as a default in XBMC since there is no setting for it.
What you can probably do is map a key on your remote or keyboard to do change audio streams, but I wouldn't know how to go about that at all.
I saw a thread a while back on how to
map audio sync +/- to a remote button, I suppose similar could be achieved. You would have to look into this yourself.
uNi
Posts: 7,135
Joined: Oct 2012
un1versal
Out of Memory (1939–2016)
Posts: 7,135
Not every video has a second stream in fact most dont...
What would happen then?
uNi
Posts: 544
Joined: May 2010
Reputation:
2
Then it would play the available (first) stream?
Posts: 7,135
Joined: Oct 2012
un1versal
Out of Memory (1939–2016)
Posts: 7,135
Would it really? I dont know.
Logic is when you save a setting for all videos that means SAVED settings for all videos, then this logic would be broken just because a 2nd stream is set as default and suddenly here comes a file that doesn't have a second stream. Unless there's a fall-back of some sort that automatically takes care of this, in that case would be ok.
Maybe you can test this and lets stop assuming what would happen. It seems to me your not sure (since your replying a question with a question) and I definitely dont know.
uNi
Posts: 6,810
Joined: Jul 2010
Reputation:
198
Audio streams are sorted following those criteria (highest on top)
- match selected audio stream (default / video setting stored with file)
- audio language if audio language in gui settings is not "original"
- number of audio channels in stream
- audio codec priority
So if none of the available audio streams matches the index in video settings, they just don't get sorted by this.
Posts: 11
Joined: Nov 2009
Reputation:
0
2012-12-19, 14:30
(This post was last modified: 2012-12-19, 14:37 by trailer.)
You can change the audio stream to a different channel using a remote such as Constellation on an iPad. I'm sure there are other ways too?