[FFmpeg-devel] [Patch] AAC encoder improvements

Claudio Freire klaussfreire at gmail.com
Sun May 5 19:01:12 CEST 2013


On Sun, May 5, 2013 at 1:30 PM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Sat, May 04, 2013 at 10:54:25PM -0300, Claudio Freire wrote:
>> On Sat, May 4, 2013 at 10:31 PM, Michael Niedermayer <michaelni at gmx.at> wrote:
>> >> >>              adjust_frame_information(cpe, chans);
>> >> >> +            if (cpe->ms_mode) {
>> >> >> +                /* Re-evaluate psy model and quantization selection based on
>> >> >> +                   MS-transformed channels */
>> >> >> +                s->psy.model->analyze(&s->psy, start_ch, coeffs, wi);
>> >> >> +                for (ch = 0; ch < chans; ch++) {
>> >> >> +                    s->cur_channel = start_ch * 2 + ch;
>> >> >> +                    s->coder->search_for_quantizers(avctx, s, &cpe->ch[ch], s->lambda);
>> >> >> +                }
>> >> >> +            }
>> >> >
>> >> > shouldnt this and the previous hunks be in seperate patches or is
>> >> > there some dependance ?
>> >>
>> >> Well, they're related, as they both pertain to joint stereo, but
>> >> there's no hard dependency between them, that's true. I did begin with
>> >> the first hunk, feeling that those artifacts were due to bad choices,
>> >> and it's not enough on its own. The really important hunk is the
>> >> second, re-doing quantization.
>> >
>> > how can it be tested ?
>> > there doesnt seem to be a difference in the output with the second
>> > hunk applied
>>
>> I imagine you enabled joint stereo? (-stereo_mode auto in ffmpeg)
>> Without it, the code doesn't do anything. And, of course, stereo input
>> that can benefit from it (any real track with vocals should).
>
> I thought it was enabled by default ...
> setting it to auto shows a difference but i see no improvment from
> the patch, PSNR worsens for most files i tried rather
> Is that expected ?

Can I have a look at the samples you've tried?

And how did you measure PSNR?


More information about the ffmpeg-devel mailing list