avcodec/libcodec2: Remove dead channel count check
This encoder has AVCodec.ch_layouts set, so that this is checked generically. Reviewed-by: Tomas Härdin <tjoppen@acc.umu.se> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
5c18934c6d
commit
e6073665c4
@ -105,7 +105,6 @@ static av_cold int libcodec2_init_encoder(AVCodecContext *avctx)
|
|||||||
|
|
||||||
//will need to be smarter once we get wideband support
|
//will need to be smarter once we get wideband support
|
||||||
if (avctx->sample_rate != 8000 ||
|
if (avctx->sample_rate != 8000 ||
|
||||||
avctx->ch_layout.nb_channels != 1 ||
|
|
||||||
avctx->sample_fmt != AV_SAMPLE_FMT_S16) {
|
avctx->sample_fmt != AV_SAMPLE_FMT_S16) {
|
||||||
av_log(avctx, AV_LOG_ERROR, "only 8 kHz 16-bit mono allowed\n");
|
av_log(avctx, AV_LOG_ERROR, "only 8 kHz 16-bit mono allowed\n");
|
||||||
return AVERROR(EINVAL);
|
return AVERROR(EINVAL);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user