Details
-
Bug
-
Resolution: Fixed
-
Major
-
None
-
None
-
Operating System: Windows 7
Platform: Intel
Description
http://forum.team-mediaportal.com/submit-patches-mediaportal-tv-server-etc-325/tvplugin-audio-stream-not-selected-correctly-73722/
When you have setup Prefer-AC3 but NOT Prefer-AC3 over language and you have a stream with MPEG and AC3 both with correct language MP selects MPEG stream instead of AC3 stream. This is caused by a useless if condition which skips the scanning of additional streams after finding the first one.
During introduction of unit tests I also found another bug:
this scenario:
1 dual mono audio track (dan/eng)
lang. prefs: "dan"
result: stereo.
it should instead choose the left audio track as this matches the user lang. selection
now the GetPreferedAudioStreamIndex method has 25+ unit tests to insure code/logic validity.
When you have setup Prefer-AC3 but NOT Prefer-AC3 over language and you have a stream with MPEG and AC3 both with correct language MP selects MPEG stream instead of AC3 stream. This is caused by a useless if condition which skips the scanning of additional streams after finding the first one.
During introduction of unit tests I also found another bug:
this scenario:
1 dual mono audio track (dan/eng)
lang. prefs: "dan"
result: stereo.
it should instead choose the left audio track as this matches the user lang. selection
now the GetPreferedAudioStreamIndex method has 25+ unit tests to insure code/logic validity.