[FFmpeg-devel] [PATCH 09/17] avcodec/libcodec2: Remove dead channel count check
Tomas Härdin
tjoppen at acc.umu.se
Wed Sep 21 16:31:51 EEST 2022
sön 2022-09-18 klockan 22:27 +0200 skrev Andreas Rheinhardt:
> This encoder has AVCodec.ch_layouts set, so that this is checked
> generically.
>
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
> ---
> libavcodec/libcodec2.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/libavcodec/libcodec2.c b/libavcodec/libcodec2.c
> index be9677ddeb..581ef04ce2 100644
> --- a/libavcodec/libcodec2.c
> +++ b/libavcodec/libcodec2.c
> @@ -105,7 +105,6 @@ static av_cold int
> libcodec2_init_encoder(AVCodecContext *avctx)
>
> //will need to be smarter once we get wideband support
> if (avctx->sample_rate != 8000 ||
> - avctx->ch_layout.nb_channels != 1 ||
> avctx->sample_fmt != AV_SAMPLE_FMT_S16) {
> av_log(avctx, AV_LOG_ERROR, "only 8 kHz 16-bit mono
> allowed\n");
> return AVERROR(EINVAL);
Should be fine
More information about the ffmpeg-devel
mailing list