[FFmpeg-devel] [PATCH] Replace hardcoded LP filter order with parameter in lsp.c

Vladimir Voroshilov voroshil
Sun May 11 04:28:25 CEST 2008


2008/5/11 Michael Niedermayer <michaelni at gmx.at>:
> Hi
>
> On Sat, May 10, 2008 at 11:55:16PM +0700, Vladimir Voroshilov wrote:
>> 2008/5/10 Michael Niedermayer <michaelni at gmx.at>:
>> > On Sat, May 10, 2008 at 01:41:39PM +0700, Vladimir Voroshilov wrote:
>> >> Hi, All
>> >>
>> >> Comparing SIPR decoder with current lsp.c code i've found that
>> >> most of LSP routines are mostly the same.
>> >>
>> >> The only difference are order of used filter.
>> >> G.729 and AMR uses 10th order LP filter, while
>> >> SIPR's 16k mode used 16th order filter.
>> >>
>> >> Attached patch removes hardcoded filter order from loops and
>> >> replaces it with parameter.
>> >>
>> >> P.S. cosmetics long-line-break (declarations only) patch will be applied
>> >> separately (should i post that trivial patch here ?)
>> > [...]
>> >> diff --git a/libavcodec/lsp.c b/libavcodec/lsp.c
>> >> index 9a09f8d..abe6380 100644
>> >> --- a/libavcodec/lsp.c
>> >> +++ b/libavcodec/lsp.c
>> >> @@ -28,30 +28,30 @@
>> >>  #include "lsp.h"
>> >>  #include "acelp_math.h"
>> >>
>> >> -void ff_acelp_reorder_lsf(int16_t* lsfq, int lsfq_min_distance, int lsfq_min, int lsfq_max)
>> >> +void ff_acelp_reorder_lsf(int16_t* lsfq, int16_t lsfq_min_distance, int16_t lsfq_min, int16_t lsfq_max, int lp_order)
>> >
>> > unrelated changes
>>
>> Removed
> [...]
>> -void ff_acelp_reorder_lsf(int16_t* lsfq, int lsfq_min_distance, int lsqf_min, int lsfq_max);
>> +void ff_acelp_reorder_lsf(int16_t* lsfq, int16_t lsfq_min_distance, int16_t lsqf_min, int16_t lsfq_max, int lp_order);
>
> hmm

This should be better.


-- 
Regards,
Vladimir Voroshilov     mailto:voroshil at gmail.com
JID: voroshil at gmail.com, voroshil at jabber.ru
ICQ: 95587719
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 09_lsp_47.diff
Type: text/x-diff
Size: 5997 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080511/9c9cab6a/attachment.diff>



More information about the ffmpeg-devel mailing list