/******************************************************************** * * * THIS FILE IS PART OF THE OggVorbis SOFTWARE CODEC SOURCE CODE. * * USE, DISTRIBUTION AND REPRODUCTION OF THIS LIBRARY SOURCE IS * * GOVERNED BY A BSD-STYLE SOURCE LICENSE INCLUDED WITH THIS SOURCE * * IN 'COPYING'. PLEASE READ THESE TERMS BEFORE DISTRIBUTING. * * * * THE OggVorbis SOURCE CODE IS (C) COPYRIGHT 1994-2009 * * by the Xiph.Org Foundation https://xiph.org/ * * * ******************************************************************** function: LPC low level routines ********************************************************************/ /* Some of these routines (autocorrelator, LPC coefficient estimator) are derived from code written by Jutta Degener and Carsten Bormann; thus we include their copyright below. The entirety of this file is freely redistributable on the condition that both of these copyright notices are preserved without modification. */ /* Preserved Copyright: *********************************************/ /* Copyright 1992, 1993, 1994 by Jutta Degener and Carsten Bormann, Technische Universita"t Berlin Any use of this software is permitted provided that this notice is not removed and that neither the authors nor the Technische Universita"t Berlin are deemed to have made any representations as to the suitability of this software for any purpose nor are held responsible for any defects of this software. THERE IS ABSOLUTELY NO WARRANTY FOR THIS SOFTWARE. As a matter of courtesy, the authors request to be informed about uses this software has found, about bugs in this software, and about any improvements that may be of general interest. Berlin, 28.11.1994 Jutta Degener Carsten Bormann *********************************************************************/ #include <stdlib.h> #include <string.h> #include <math.h> #include "os.h" #include "smallft.h" #include "lpc.h" #include "scales.h" #include "misc.h" /* Autocorrelation LPC coeff generation algorithm invented by N. Levinson in 1947, modified by J. Durbin in 1959. */ /* Input : n elements of time doamin data Output: m lpc coefficients, excitation energy */ float vorbis_lpc_from_data(float *data,float *lpci,int n,int m){ … } void vorbis_lpc_predict(float *coeff,float *prime,int m, float *data,long n){ … }