mirror of
https://mirror.skon.top/https://github.com/FFmpeg/FFmpeg
synced 2026-04-20 21:00:41 +08:00
avcodec/sbcdec: Don't set encoder-only fields
ch_layouts, sample_fmts and supported_samplerates are of no use for a decoder, so don't set them. In this case this fixes an inconsistency: ch_layouts contained mono and stereo, yet lateron the AVCodecContext's ch_layout is always populated with an AV_CHANNEL_ORDER_UNSPEC layout. Reviewed-by: James Almer <jamrial@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
@@ -371,7 +371,4 @@ const FFCodec ff_sbc_decoder = {
|
||||
.init = sbc_decode_init,
|
||||
FF_CODEC_DECODE_CB(sbc_decode_frame),
|
||||
.p.capabilities = AV_CODEC_CAP_DR1 | AV_CODEC_CAP_CHANNEL_CONF,
|
||||
CODEC_CH_LAYOUTS(AV_CHANNEL_LAYOUT_MONO, AV_CHANNEL_LAYOUT_STEREO),
|
||||
CODEC_SAMPLEFMTS(AV_SAMPLE_FMT_S16P),
|
||||
CODEC_SAMPLERATES(16000, 32000, 44100, 48000),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user