mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2026-01-23 23:21:06 +01:00
swr: audioconvert: consider mono to be planar
This way it will be handled by the planar==planar SIMD Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
72ae583b7d
commit
f10aeab69c
1 changed files with 6 additions and 0 deletions
|
|
@ -124,6 +124,12 @@ AudioConvert *swri_audio_convert_alloc(enum AVSampleFormat out_fmt,
|
|||
ctx = av_mallocz(sizeof(*ctx));
|
||||
if (!ctx)
|
||||
return NULL;
|
||||
|
||||
if(channels == 1){
|
||||
in_fmt = av_get_planar_sample_fmt( in_fmt);
|
||||
out_fmt = av_get_planar_sample_fmt(out_fmt);
|
||||
}
|
||||
|
||||
ctx->channels = channels;
|
||||
ctx->conv_f = f;
|
||||
ctx->ch_map = ch_map;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue