|
SIP Communicator: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.java.sip.communicator.impl.media.codec.audio.g729.Pitch
class Pitch
Long Term Prediction Routines
| Constructor Summary | |
|---|---|
Pitch()
|
|
| Method Summary | |
|---|---|
(package private) static int |
enc_lag3(int T0,
int T0_frac,
IntReference T0_min,
IntReference T0_max,
int pit_min,
int pit_max,
int pit_flag)
Function enc_lag3() Encoding of fractional pitch lag with 1/3 resolution. |
(package private) static float |
g_pitch(float[] xn,
float[] y1,
float[] g_coeff,
int l_subfr)
Compute adaptive codebook gain and compute |
(package private) static int |
pitch_fr3(float[] exc,
int exc_offset,
float[] xn,
float[] h,
int l_subfr,
int t0_min,
int t0_max,
int i_subfr,
IntReference pit_frac)
Find the pitch period with 1/3 subsample resolution |
(package private) static int |
pitch_ol(float[] signal,
int signal_offset,
int pit_min,
int pit_max,
int l_frame)
Compute the open loop pitch lag. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
Pitch()
| Method Detail |
|---|
static int pitch_ol(float[] signal,
int signal_offset,
int pit_min,
int pit_max,
int l_frame)
signal - input : signal to compute pitch
s[-PIT_MAX : l_frame-1]signal_offset - input : signal offsetpit_min - input : minimum pitch lagpit_max - input : maximum pitch lagl_frame - input : error minimization window
static int pitch_fr3(float[] exc,
int exc_offset,
float[] xn,
float[] h,
int l_subfr,
int t0_min,
int t0_max,
int i_subfr,
IntReference pit_frac)
exc - input : excitation bufferexc_offset - input : excitation buffer offsetxn - input : target vectorh - input : impulse response of filters.l_subfr - input : Length of frame to compute pitcht0_min - input : minimum value in the searched ranget0_max - input : maximum value in the searched rangei_subfr - input : indicator for first subframepit_frac - output: chosen fraction
static float g_pitch(float[] xn,
float[] y1,
float[] g_coeff,
int l_subfr)
xn - input : target vectory1 - input : filtered adaptive codebook vectorg_coeff - output: l_subfr - input : vector dimension
static int enc_lag3(int T0,
int T0_frac,
IntReference T0_min,
IntReference T0_max,
int pit_min,
int pit_max,
int pit_flag)
The pitch range for the first subframe is divided as follows:
19 1/3 to 84 2/3 resolution 1/3
85 to 143 resolution 1
The period in the first subframe is encoded with 8 bits.
For the range with fractions:
index = (T-19)*3 + frac - 1; where T=[19..85] and frac=[-1,0,1]
and for the integer only range
index = (T - 85) + 197; where T=[86..143]
----------------------------------------------------------------------
For the second subframe a resolution of 1/3 is always used, and the
search range is relative to the lag in the first subframe.
If t0 is the lag in the first subframe then
t_min=t0-5 and t_max=t0+4 and the range is given by
t_min - 2/3 to t_max + 2/3
The period in the 2nd subframe is encoded with 5 bits:
index = (T-(t_min-1))*3 + frac - 1; where T[t_min-1 .. t_max+1]
T0 - input : Pitch delayT0_frac - input : Fractional pitch delayT0_min - in/out: Minimum search delayT0_max - in/out: Maximum search delaypit_min - input : Minimum pitch delaypit_max - input : Maximum pitch delaypit_flag - input : Flag for 1st subframe
|
SIP Communicator: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||