diff options
author | sr55 <[email protected]> | 2018-04-23 21:52:42 +0100 |
---|---|---|
committer | sr55 <[email protected]> | 2018-04-23 21:52:52 +0100 |
commit | de49d8c04a8e31ef41368c5a09223f2d84c74944 (patch) | |
tree | 10877b8c6f13fdf008cf459e42cd1ddb20711380 /win/CS/HandBrakeWPF/Services/Encode | |
parent | 128041edb0a8183bb4b27d906e31df4e3dfc32f4 (diff) |
WinGui: Add support for setting mixdown, bitrate, sample rate, gain and DRC for the passthru encoder on the audio behaviour screen. This is used for the audio fallback encoder. #1291
Diffstat (limited to 'win/CS/HandBrakeWPF/Services/Encode')
-rw-r--r-- | win/CS/HandBrakeWPF/Services/Encode/Model/Models/AudioTrack.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/win/CS/HandBrakeWPF/Services/Encode/Model/Models/AudioTrack.cs b/win/CS/HandBrakeWPF/Services/Encode/Model/Models/AudioTrack.cs index 7cc073125..24a56a8b2 100644 --- a/win/CS/HandBrakeWPF/Services/Encode/Model/Models/AudioTrack.cs +++ b/win/CS/HandBrakeWPF/Services/Encode/Model/Models/AudioTrack.cs @@ -113,9 +113,11 @@ namespace HandBrakeWPF.Services.Encode.Model.Models { AudioEncoder chosenEncoder = track.Encoder; HBAudioEncoder encoderInfo = HandBrakeEncoderHelpers.GetAudioEncoder(EnumHelper<AudioEncoder>.GetShortName(track.Encoder)); + HBAudioEncoder fallbackEncoderInfo; if (track.IsPassthru && (sourceTrack.Codec & encoderInfo.Id) == 0) { chosenEncoder = fallback; + encoderInfo = HandBrakeEncoderHelpers.GetAudioEncoder(EnumHelper<AudioEncoder>.GetShortName(track.Encoder)); } this.scannedTrack = sourceTrack; @@ -125,7 +127,9 @@ namespace HandBrakeWPF.Services.Encode.Model.Models this.mixDown = track.MixDown != null ? track.MixDown.ShortName : "dpl2"; // If the mixdown isn't supported, downgrade it. - if (track.MixDown != null && encoderInfo != null && !HandBrakeEncoderHelpers.MixdownIsSupported(track.MixDown, encoderInfo, sourceTrack.ChannelLayout)) + + + if (track.IsPassthru && track.MixDown != null && encoderInfo != null && !HandBrakeEncoderHelpers.MixdownIsSupported(track.MixDown, encoderInfo, sourceTrack.ChannelLayout)) { HBMixdown changedMixdown = HandBrakeEncoderHelpers.GetDefaultMixdown(encoderInfo, (ulong)sourceTrack.ChannelLayout); if (changedMixdown != null) |