From 833f974cc3b7b4a50f9c4a76686950a9dd395e70 Mon Sep 17 00:00:00 2001 From: Rodeo Date: Sat, 11 Aug 2012 18:30:28 +0000 Subject: Improve last commit. While the AC3 decoder doesn't use hb_ff_layout_xlat(), the code I added to it really belongs in hb_audio_resample. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4899 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- libhb/audio_resample.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libhb/audio_resample.c') diff --git a/libhb/audio_resample.c b/libhb/audio_resample.c index 45d2fdf42..94ab3b531 100644 --- a/libhb/audio_resample.c +++ b/libhb/audio_resample.c @@ -53,6 +53,11 @@ int hb_audio_resample_update(hb_audio_resample_t *resample, int ret, resample_changed; new_channel_layout = hb_ff_layout_xlat(new_channel_layout, new_channels); + if (new_channel_layout == AV_CH_LAYOUT_STEREO_DOWNMIX) + { + // Dolby Surround is Stereo when it comes to remixing + new_channel_layout = AV_CH_LAYOUT_STEREO; + } resample->resample_needed = (resample->resample_needed || -- cgit v1.2.3