[FFmpeg-devel] [PATCH] make lsp2poly() a non-static function

Michael Niedermayer michaelni
Tue Nov 24 13:17:57 CET 2009


On Sun, Nov 22, 2009 at 07:06:16PM +0100, Vitor Sessak wrote:
> $subj, it is used for SIPR for implementing its broken version of 
> ff_acelp_lspd2lpc():
>
>> static void lsp2lpc_8k5(const double *isp, float *Az, int length)
>> {
>>     int lp_half_order = length >> 1;
>>     double pa[lp_half_order+1], qa[lp_half_order];
>>     int i,j;
>>     ff_lsp2polyf(isp    , pa, lp_half_order    );
>>     ff_lsp2polyf(isp + 1, qa, lp_half_order - 1);
>>     for(i=lp_half_order-1; i>1; i--)
>>         qa[i] -= qa[i-2];
>>     for(i=1, j=length-1;i<lp_half_order;i++,j--) {
>>         float paf = (pa[i] + qa[i]) * 0.5;
>>         float qaf = (pa[i] - qa[i]) * 0.5;
>>         Az[i-1]  = paf + qaf * isp[length - 1];
>>         Az[j-1]  = qaf + paf * isp[length - 1];
>>     }
>>     Az[lp_half_order-1] = (1.0 + isp[length - 1]) * pa[lp_half_order] * 
>> 0.5;
>>     Az[length-1] = isp[length - 1];
>> }
>
> -Vitor

>  lsp.c |   16 +++-------------
>  lsp.h |   12 ++++++++++++
>  2 files changed, 15 insertions(+), 13 deletions(-)
> 6734302079d5dca86947955696a5e24c0ff4a232  lsp2polyf.diff

ok

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

No great genius has ever existed without some touch of madness. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20091124/be6692d1/attachment.pgp>



More information about the ffmpeg-devel mailing list