[FFmpeg-devel] [PATCH] ALS decoder

Thilo Borgmann thilo.borgmann
Sat Sep 12 00:45:49 CEST 2009


Michael Niedermayer schrieb:
> On Thu, Sep 10, 2009 at 09:52:34PM +0200, Thilo Borgmann wrote:
>> Revision 18 attached.
> 
> [...]
> 
>> +    if (!sconf->bgmc && !sconf->sb_part)
>> +        log2_sub_blocks = 0;
>> +    else if (sconf->bgmc && sconf->sb_part)
> 
> {}
> 
> [...]
>> +    // reconstruct all samples from residuals
>> +    if (ra_block) {
>> +        for (smp = 0; smp < block_length; smp++) {
>> +            unsigned int dequant = smp < opt_order;
>> +            unsigned int max     = dequant ? smp : opt_order;
>> +
>> +            y = 1 << 19;
>> +
>> +            for (sb = 0; sb < max; sb++)
>> +                y += MUL64(lpc_cof[sb],raw_samples[smp - (sb + 1)]);
>> +
>> +            raw_samples[smp] -= y >> 20;
>> +            if (dequant)
>> +                parcor_to_lpc(smp, quant_cof, lpc_cof);
>> +        }
> 
> this loop can be split into
> smp < opt_order
> and
> opt_order <= smp < block_length
> 
> the second onecan be merged with the loop in the else below
> 

All part of revision 19. Thanks!

-Thilo



More information about the ffmpeg-devel mailing list