[FFmpeg-devel] MPEG TS encoding problem on change from stereo to mono, pay for fix

Reimar Döffinger Reimar.Doeffinger
Thu Nov 18 21:07:00 CET 2010

On Thu, Nov 18, 2010 at 05:09:20PM +0100, Andreas Unterhuber wrote:
> I published at https://roundup.ffmpeg.org/issue2292 a bug that causes strange noise after change of mono to stereo or similar. 
> If you can commit a fix to make changing audio channel rates in the demo file (attached in the bug tracker or I will provide another bigger file) work correctly, I'll pay $350.

Tip for anyone who needs money:
Look at ffmpeg.c, line 804:
    if (ost->audio_resample && !ost->resample) {
This condition is insufficent, ost->resample cannot be re-used
but must be freed and re-created if the number of channels
from the decoder changed.
Strictly, this all also should handle the channel mask properly,
but that is work beyond this bug-fix.

More information about the ffmpeg-devel mailing list