aboutsummaryrefslogtreecommitdiffstats
path: root/libswresample/swresample.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-08-18 11:52:11 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2016-08-18 11:52:11 +0200
commit30b2611ed3102c53a8aa96c71acf5dadb69997c8 (patch)
tree85aff1f741c3d7901c25657ebb8f0a1045fcef55 /libswresample/swresample.c
parent946acacdcdff7eb9ac6430691ac6121516da9083 (diff)
downloadffmpeg-30b2611ed3102c53a8aa96c71acf5dadb69997c8.tar.gz
swresample: Skip over dither steps if dithering scale is 0
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libswresample/swresample.c')
-rw-r--r--libswresample/swresample.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libswresample/swresample.c b/libswresample/swresample.c
index ade81efd2c..b8ad9486eb 100644
--- a/libswresample/swresample.c
+++ b/libswresample/swresample.c
@@ -176,6 +176,8 @@ av_cold int swr_init(struct SwrContext *s){
s->int_sample_fmt= s->user_int_sample_fmt;
+ s->dither.method = s->user_dither_method;
+
if(av_get_channel_layout_nb_channels(s-> in_ch_layout) > SWR_CH_MAX) {
av_log(s, AV_LOG_WARNING, "Input channel layout 0x%"PRIx64" is invalid or unsupported.\n", s-> in_ch_layout);
s->in_ch_layout = 0;