jellyfin/tests/Jellyfin.Model.Tests/Dlna
gnattu 162ea38a95
Check MaxAudioChannels for directAudioStream candidates (#12319)
* Check MaxAudioChannels for directAudioStream candidates

The current stream builder logic does not check the channel limit when determining if the audio stream can be directly used, and this can cause some undesired effects:

- A high channel count surround sound stream might be picked even if a stereo one exists when the user requires stereo audio.

- The user's preferred audio codec might not be respected during the downmix because the requested codec is now forced to be the same as the original source.

Signed-off-by: gnattu <gnattuoc@me.com>

* Fix unit test

Signed-off-by: gnattu <gnattuoc@me.com>

* Set correct transcode reason and target channels for unit test

Signed-off-by: gnattu <gnattuoc@me.com>

* Match old stream selection behavior

Signed-off-by: gnattu <gnattuoc@me.com>

* Fix reason matching

Signed-off-by: gnattu <gnattuoc@me.com>

---------

Signed-off-by: gnattu <gnattuoc@me.com>
2024-07-29 00:11:59 +02:00
..
ContainerProfileTests.cs Add regression test for ContainerProfile.ContainsContainer 2021-05-05 13:33:34 +02:00
StreamBuilderTests.cs Check MaxAudioChannels for directAudioStream candidates (#12319) 2024-07-29 00:11:59 +02:00