mirror of https://git.ffmpeg.org/ffmpeg.git
swr: fix buf_set() so it works with input == output
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
bdbfd4569d
commit
5027e3daf7
|
@ -394,7 +394,7 @@ static void buf_set(AudioData *out, AudioData *in, int count){
|
||||||
for(ch=0; ch<out->ch_count; ch++)
|
for(ch=0; ch<out->ch_count; ch++)
|
||||||
out->ch[ch]= in->ch[ch] + count*out->bps;
|
out->ch[ch]= in->ch[ch] + count*out->bps;
|
||||||
}else{
|
}else{
|
||||||
for(ch=0; ch<out->ch_count; ch++)
|
for(ch=out->ch_count-1; ch>=0; ch--)
|
||||||
out->ch[ch]= in->ch[0] + (ch + count*out->ch_count) * out->bps;
|
out->ch[ch]= in->ch[0] + (ch + count*out->ch_count) * out->bps;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue