diff --git a/libswresample/rematrix.c b/libswresample/rematrix.c index da817e14556ca572eb07679fc2b14d11105ec401..e588fe973e2ace4a8697b4139e414fe6f4fc0055 100644 --- a/libswresample/rematrix.c +++ b/libswresample/rematrix.c @@ -280,6 +280,9 @@ int swri_rematrix(SwrContext *s, AudioData *out, AudioData *in, int len, int mus for(out_i=0; out_i<out->ch_count; out_i++){ switch(s->matrix_ch[out_i][0]){ + case 0: + memset(out->ch[out_i], 0, len * (s->int_sample_fmt == AV_SAMPLE_FMT_FLT ? sizeof(float) : sizeof(int16_t))); + break; case 1: in_i= s->matrix_ch[out_i][1]; if(mustcopy || s->matrix[out_i][in_i]!=1.0){