jellyfin/MediaBrowser.Model/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
..
CodecProfile.cs
CodecType.cs
ConditionProcessor.cs Migrate VideoRange and VideoRangeType to Enum 2023-06-28 12:02:20 +02:00
ContainerProfile.cs Enable nullable for more files 2023-03-07 21:51:48 +01:00
DeviceProfile.cs Remove DLNA-specific DeviceProfile code (#10850) 2024-01-12 09:24:32 -07:00
DirectPlayProfile.cs Enable nullable for more files 2023-03-07 21:51:48 +01:00
DlnaProfileType.cs Store lyrics in the database as media streams (#9951) 2024-02-26 05:09:40 -07:00
EncodingContext.cs
ITranscoderSupport.cs Enable nullable for more files 2023-03-07 21:51:48 +01:00
MediaOptions.cs Update stylecop.analyzers to v1.2.0-beta.507 2023-06-22 00:39:32 +02:00
PlaybackErrorCode.cs
ProfileCondition.cs
ProfileConditionType.cs
ProfileConditionValue.cs
ResolutionConfiguration.cs
ResolutionNormalizer.cs Remove unused lines 2023-06-20 03:50:02 +08:00
ResolutionOptions.cs
StreamBuilder.cs Check MaxAudioChannels for directAudioStream candidates (#12319) 2024-07-29 00:11:59 +02:00
StreamInfo.cs Add EnableAudioVbrEncoding to TranscodingProfile 2024-07-17 21:27:35 +08:00
SubtitleDeliveryMethod.cs
SubtitleProfile.cs
SubtitleStreamInfo.cs
TranscodeSeekInfo.cs
TranscodingProfile.cs Default EnableAudioVbrEncoding to true in TranscodingProfile 2024-07-17 21:27:35 +08:00