[FFmpeg-devel] Make ffmpeg.c and ffplay.c use avctx->request_channels
Wed Dec 12 14:32:57 CET 2007
Michael Niedermayer wrote:
> you assume that every codec with >2 chans can downmix this is likely not the
> a CODEC_CAP_DOWNMIX could be added or just check the channels number after
Hm, yes, this is not so good.
Another option is to make request_channels 'advisory' only.
Ie. if the decoder cannot satisfy the requirement or just don't
know about any downmixing then avctx->channels will stay
It is then up to the caller to check if "avctx->channels" has
the desired value. (bail out, or invoke a "dumb" downmixer)
If so, I would suggest that we move the guts of audio resampling setup
into do_audio_out() and do this on demand (based on the outcome
More information about the ffmpeg-devel