Option to automatically choose the audio stream with most channels

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
dteirney Offline
Team-XBMC Developer
Posts: 830
Joined: Jul 2007
Reputation: 6
Location: New Zealand
Lightbulb  Option to automatically choose the audio stream with most channels
Post: #1
We are playing back a lot of TV shows recorded using Myth TV.

Many of the TV shows we watch here in New Zealand are broadcast in digital with 2 audio streams.
* 2 channel AAC stereo (first stream)
* 5.1 surround sound AC3 (second stream)

We can change the stream being used through the Audio settings, but are having to do this for all TV shows or Movies that we watch through myth://. I've tried "Save as default for all" with the second AC3 stream chosen but that didn't seem to work.

Would be great if XBMC could automatically chose the audio stream with the most channels if there is more than one.
find quote
jmarshall Offline
Team-XBMC Developer
Posts: 26,221
Joined: Oct 2003
Reputation: 178
Post: #2
WTF are they doing it backwards. Stupid NZers! TV1 and 2 have an ac3 stream as well, huh? I shall have a play with the new telly...

Request sounds reasonable though - if a default stream isn't previously set, picking the "best" should be something that can be done. I suggest taking a search of trac and seeing whether there's a ticket already for this, and if not, add one Smile

Cheers,
Jonathan

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


[Image: badge.gif]
find quote
dteirney Offline
Team-XBMC Developer
Posts: 830
Joined: Jul 2007
Reputation: 6
Location: New Zealand
Post: #3
It's only TV3 that is currently broadcasting multiple audio streams. That seems to be the channel where we have lots of TV shows and Movies recorded though...

I'd be surprised if some of the other channels don't support surround sound down the track though.

Couldn't find an existing ticket in trac that covered this so there's a new one at http://trac.xbmc.org/ticket/5773.
find quote
dteirney Offline
Team-XBMC Developer
Posts: 830
Joined: Jul 2007
Reputation: 6
Location: New Zealand
Post: #4
There's a patch attached to the trac ticket if anyone wants to give this a go.
find quote
whittaker007 Offline
Junior Member
Posts: 10
Joined: Jan 2010
Reputation: 0
Post: #5
It's not just recorded TV that follows the dual-audio embedding format - Apple's movies in .m4v format have a 2-channel AAC first audio track, and 5.1 AC3 as a second audio track.

This is so that movies can be played on devices and software without 5.1 digital audio support, and on the assumption that those which do will also support track switching.

Subscribing to this issue since I encode all of my video this way, and manually switching audio tracks every time I watch a video is a real pain and XBMC doesn't remember default track selection for new media after a restart.

I'd love to try the patch but I'm currently using Windows for my media centre since I couldn't get MythTV working and I can't run iTunes on Linux. Hope this makes it to a release soon, but glad that someone is working on it. Smile
find quote
frater Offline
Fan
Posts: 312
Joined: Jan 2005
Reputation: 0
Post: #6
Will it prefer DTS over an AC3 if both AC3 & DTS flags are checked?
find quote
dteirney Offline
Team-XBMC Developer
Posts: 830
Joined: Jul 2007
Reputation: 6
Location: New Zealand
Post: #7
frater Wrote:Will it prefer DTS over an AC3 if both AC3 & DTS flags are checked?

Yes. From best to worst:

  1. Lossless FLAC
  2. DTS-HD Master Audio (aka DTS++)
  3. Dolby TrueHD
  4. Dolby Digital Plus
  5. DTS
  6. Dolby Digital (AC3)
  7. Anything else

Use MythTV for recording TV? Try the integrated MythTV support in XBMC Media Center. Now with commercial skip support built-in and integration with the Movie database!
find quote
dallasnights Offline
Fan
Posts: 487
Joined: Jan 2011
Reputation: 0
Post: #8
interesting how do you apply the patch love to try it out

Thanks all
find quote
migueld Offline
Fan
Posts: 361
Joined: Sep 2008
Reputation: 2
Post: #9
whittaker007 Wrote:It's not just recorded TV that follows the dual-audio embedding format - Apple's movies in .m4v format have a 2-channel AAC first audio track, and 5.1 AC3 as a second audio track.

Yes this is a big issue for me as well, I have encoded my movies with the Apple TV preset which has AAC first and the AC3 second. It would be great if XMBC did something about this so that the user doesn't have to change tracks all the time.
find quote
Uxorious Offline
Junior Member
Posts: 18
Joined: Nov 2009
Reputation: 0
Post: #10
Man that was an annoying change to make it into Eden.
A ton of my movies has a 5.1 AAC (high bitrate = high quality) track first, and then foreign language AC3 tracks following.
Now it plays them all wrong.

I couldn't find an option in XBMC to pick behavior ... I guess I will request adding one?
Good options would be:
Play first track.
Play best track (the priority list of codecs above is very subjective!)
Try matching language.
find quote
Montellese Online
Team-XBMC Developer
Posts: 3,830
Joined: Jan 2009
Reputation: 36
Location: Switzerland
Post: #11
You should make sure your files have a default audio track set, then you won't run into this problem. Furthermore I'm working on https://github.com/xbmc/xbmc/pull/700 which will try to open the audio stream with a specific language (if so configured).

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.

[Image: badge.gif]
find quote
Uxorious Offline
Junior Member
Posts: 18
Joined: Nov 2009
Reputation: 0
Post: #12
(2012-03-25 09:03)Montellese Wrote:  You should make sure your files have a default audio track set, then you won't run into this problem.

I don't believe MP4 has any support for this.

(2012-03-25 09:03)Montellese Wrote:  Furthermore I'm working on https://github.com/xbmc/xbmc/pull/700 which will try to open the audio stream with a specific language (if so configured).

Since everybody will have different preferences, we should really have a GUI option to pick the desired behavior:
1) No auto picking - always pick default/first track.
2) Pick audio language to match video language.
3) Pick most channels / "best" codec.
4) Match GUI language.
5) Who knows.

Another big problem for me is that AAC is considered a worse codec than AAC in the current implementation of XBMC.
This is completely incorrect for many files (AAC can easily be a high-quality encode from LPCM or similar source).
find quote