亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? owng728.h

?? G.711,G.723.1,G.726,G.729,GSM CODEC C/C++ code
?? H
字號:
/*/////////////////////////////////////////////////////////////////////////////
//
//                  INTEL CORPORATION PROPRIETARY INFORMATION
//     This software is supplied under the terms of a license agreement or
//     nondisclosure agreement with Intel Corporation and may not be copied
//     or disclosed except in accordance with the terms of that agreement.
//          Copyright(c) 2005 Intel Corporation. All Rights Reserved.
//
//     Intel(R) Integrated Performance Primitives
//     USC - Unified Speech Codec interface library
//
// By downloading and installing USC codec, you hereby agree that the
// accompanying Materials are being provided to you under the terms and
// conditions of the End User License Agreement for the Intel(R) Integrated
// Performance Primitives product previously accepted by you. Please refer
// to the file ipplic.htm located in the root directory of your Intel(R) IPP
// product installation for more information.
//
// A speech coding standards promoted by ITU, ETSI, 3GPP and other
// organizations. Implementations of these standards, or the standard enabled
// platforms may require licenses from various entities, including
// Intel Corporation.
//
//
// Purpose: G.728 speech codec: internal definitions.
//
*/

#ifndef _OWN_G728_H_
#define _OWN_G728_H_
#include <ipps.h>
#include "g728api.h"

#include "scratchmem.h"

#define ENC_KEY 0xecd728
#define DEC_KEY 0xdec728

#define   G728_CODECFUN(type,name,arg)                extern type name arg

#define G728_TRUE           1
#define G728_FALSE          0

/* G728 Constants */

#define AGCFAC     16220 /* AGC adaptation speed controlling factor */
#define AGCFAC1    20972 /*  The value of (1 - AGCFAC)*/
#define IDIM           5 /*  Vector dimension (excitation block size)*/
#define GOFF       16384 /*  Log-gain offset value*/
#define KPDELTA        6 /*  Allowed deviation from previous pitch period*/
#define KPMIN         20 /*  Minimum pitch period (samples)*/
#define KPMAX        140 /*  Maximum pitch period (samples)*/
#define LPC           50 /*  Synthesis filter order*/
#define LPCLG         10 /*  Log-gain predictor order*/
#define LPCW          10 /*  Perceptual weighting filter order*/
#define NCWD         128 /*  Shape codebook size (number of codevectors)*/
#define NCWD3_4      96
#define NCWD4        32
#define NFRSZ         20 /*  Frame size (adaptation cycle size in samples)*/
#define NG             8 /*  Gain codebook size (number of gain levels)*/
#define NONR          35 /*  Number of non-recursive window samples for synthesis filter*/
#define NONRLG        20 /*  Number of non-recursive window samples for log-gain predictor*/
#define NONRW         30 /*  Number of non-recursive window samples for weighting filter*/
#define NPWSZ        100 /*  Pitch analysis window size (samples)*/
#define NUPDATE        4 /*  Predictor update period (in terms of vectors)*/
#define PPFTH       9830 /*  Tap threshold for turning off pitch postfilter*/
#define PPFZCF      9830 /*  Pitch postfilter zero controlling factor*/
#define TAPTH      26214 /*  Tap threshold for fundamental pitch replacement*/
#define TILTF       4915 /*  Spectral tilt compensation controlling factor*/

#define REXPWMEMSIZE (8+LPCW+1+1+60)
#define REXPLGMEMSIZE (8+LPCLG+1+1+34)
#define REXPMEMSIZE (8+LPC+1+1+105+21)
#define COMBMEMSIZE (LPC+11 + 2*(LPCW+1))
#define IIRMEMSIZE (2*LPCW)
#define STPMEMSIZE (2*LPCW)
#define SYNTHMEMSIZE (LPC+11)

/* Rate 12.8 specific*/

#define NG_128         4 /* Gain codebook size (number of gain levels)*/
#define NG_96          4 /* Gain codebook size (number of gain levels)*/

#define ST_BUFF_SIZ

/* G728I coder specific*/
#define FESIZE         4 /* Number of 2.5 msec adaptation cycles in a frame erasure (FE)
                            e.g.: 1 for 2.5 msec FEs, 4 for 10 msec FEs.
                            FEs may be any multiple of 2.5 msec. SET BY USER*/

#define AFTERFEMAX    16 /* Maximum 2.5 ms frames for gain clipping */

/*                                                                            */
void VscaleFive_16s(const Ipp16s* pSrc, Ipp16s* pDst, Ipp16s rangeScale, Ipp16s* pScale);
void VscaleOne_Range30_32s(const Ipp32s* pSrc, Ipp32s* pDst, Ipp16s* pScale);

void Divide_16s(Ipp16s num, Ipp16s numnls, Ipp16s den, Ipp16s dennls, Ipp16s *quo, Ipp16s *quonls);
/*void SimpDiv(Ipp16s num, Ipp16s den, Ipp32s *aa0);*/

void LevinsonDurbin(const short *rtmp, int ind1, int ind2, short *pTmpSynFltrCoeffs, short *rc1,
                    short *alphatmp, short *scaleSynFltrCoeffs, short *illcondp, short *illcond);

void GetShapeGainIdxs(Ipp16s codebookIdx, Ipp32s *pShapeIdx, Ipp32s *pGainIdx, Ipp16s rate);

/* VQ functions*/
void VQ_target_vector_calc(Ipp16s *sw, Ipp16s *zir, Ipp16s *target);
void Impulse_response_vec_calc(Ipp16s *a, Ipp16s *pWghtFltrCoeffs, Ipp16s *h);
void Time_reversed_conv(Ipp16s *h, Ipp16s *target, Ipp16s nlstarget, Ipp16s *pn);
void VQ_target_vec_norm(Ipp16s linearGain, Ipp16s scaleGain, Ipp16s* target, Ipp16s* nlstarget);
void Excitation_VQ_and_gain_scaling(Ipp16s linearGain, const Ipp16s* tbl, Ipp16s* et);

/* Adapter functions*/
void WeightingFilterCoeffsCalc(Ipp16s *pTmpWghtFltrCoeffs, Ipp16s coeffsScale, Ipp16s *pVecWghtFltrCoeffs);
void LoggainLinearPrediction(Ipp16s *pVecLGPredictorCoeffs, Ipp16s *pLGPredictorState, Ipp32s *pGainLog);
void InverseLogarithmCalc(Ipp32s gainLog, Ipp16s *pLinearGain, Ipp16s *pScaleGain);
Ipp16s LoggainAdderLimiter(Ipp32s pGainLog, Ipp16s gainIdx, Ipp16s shapeIdx,
                           const Ipp16s *pCodebookGain);
void BandwidthExpansionModul(const Ipp16s* pConstBroadenVector, Ipp16s* pTmpCoeffs, Ipp16s coeffsScale,
                             Ipp16s* pCoeffs, int len);
void BandwidthExpansionModulFE(const Ipp16s* pConstBroadenVector, Ipp16s* pTmpCoeffs, Ipp16s coeffsScale,
                               Ipp16s* pCoeffs, int len, short countFE, short illCond);
/* Postfilter functions*/
void AbsSum_G728_16s32s(Ipp16s* pSrc, Ipp32s* pSum);
void ScaleFactorCalc(Ipp32s sumunfil, Ipp32s sumfil, Ipp16s *scale, Ipp16s *nlsscale);
void FirstOrderLowpassFilter_OuputGainScaling(Ipp16s scale, Ipp16s nlsscale, Ipp16s *scalefil,
                                       Ipp16s *temp, Ipp16s *spf);

void STPCoeffsCalc(Ipp16s *pLPCFltrCoeffs, Ipp16s scaleLPCFltrCoeffs,
                   Ipp16s *pstA, Ipp16s rc1, Ipp16s *tiltz);

/*Pitch search functions*/
void LTPCoeffsCalc(const Ipp16s *sst, Ipp32s kp, Ipp16s *gl, Ipp16s *glb, Ipp16s *pTab);

void Set_Flags_and_Scalin_Factor_for_Frame_Erasure(Ipp16s fecount, Ipp16s ptab, Ipp16s kp, Ipp16s* fedelay, Ipp16s* fescale,
                                                   Ipp16s* nlsfescale, Ipp16s* voiced, Ipp16s* etpast,
                                                   Ipp16s *avmag, Ipp16s *nlsavmag);
void Log_gain_Limiter_after_erasure(Ipp32s *pGainLog, Ipp32s ogaindb, Ipp16s afterfe);
void ExcitationSignalExtrapolation(Ipp16s voiced, Ipp16s *fedelay, Ipp16s fescale, Ipp16s nlsfescale, Ipp16s* etpast,
                                     Ipp16s *et, Ipp16s *nlset, Ipp16s *seed);
void UpdateExcitationSignal(Ipp16s *etpast, Ipp16s *et, Ipp16s nlset);
void UpdateLGPredictorState(Ipp16s *et, Ipp16s *pLGPredictorState);


typedef struct {
   Ipp32u        objSize;
   Ipp32s        key;
   G728_Rate     rate ;      /* rate*/
   G728_Type     type;  /* Type of decoder;*/
}own_G728_Obj_t;

struct _G728Encoder_Obj {
   Ipp16s   vecSyntFltrCoeffs[LPC      +6]; /*a*/
   Ipp16s   tmpSyntFltrCoeffs[LPC      +6]; /*atmp*/
   Ipp16s   vecWghtFltrCoeffs[2*LPCW   +4]; /* awp + awz */
   Ipp16s   tmpWghtFltrCoeffs[LPCW     +6]; /* awztmp */
   Ipp16s   vecLGPredictorCoeffs[LPCLG +6]; /*gp*/
   Ipp16s   tmpLGPredictorCoeffs[LPCLG +6]; /*gptmp*/
   Ipp16s   vecLGPredictorState[LPCLG   +6];/*gstate*/
   Ipp16s   y2[NCWD        +0];
   Ipp16s   h[IDIM         +3];
   Ipp16s   st[IDIM        +3];
   Ipp16s   sttmp[4*IDIM   +4];
   Ipp16s   nlssttmp[4     +4];
   Ipp16s   stmp[4*IDIM    +4];
   Ipp16s   r[11           +5];
   Ipp16s   rtmp[LPC+1     +5];


   own_G728_Obj_t    objPrm;
   const Ipp16s *pGq;
   const Ipp16s *pNgq;
   const Ipp16s *pCodebookGain;
   IppsIIRState_G728_16s            *wgtMem;
   IppsWinHybridState_G728_16s      *rexpMem;
   IppsWinHybridState_G728_16s      *rexpwMem;
   IppsWinHybridState_G728_16s      *rexplgMem;
   IppsCombinedFilterState_G728_16s *combMem;
   Ipp16s        illcond;
   Ipp16s        illcondw;
   Ipp16s        illcondg;
   Ipp16s        illcondp;
   Ipp16s        scaleWghtFltrCoeffs; /* nlsawztmp */
   Ipp16s        scaleSyntFltrCoeffs; /*nlsatmp*/
   Ipp16s        nlsst;
   Ipp16s        scaleLGPredictorCoeffs;/*nlsgptmp*/
   Ipp16s        icount;
};

struct _G728Decoder_Obj {
   Ipp16s   vecSyntFltrCoeffs[LPC                   +6]; /*a*/
   Ipp16s   tmpSyntFltrCoeffs[LPC                +6]; /*atmp*/
   Ipp16s   vecLGPredictorCoeffs[LPCLG                +6];/*gp*/
   Ipp16s   tmpLGPredictorCoeffs[LPCLG             +6];/*gptmp*/
   Ipp16s   vecLGPredictorState[LPCLG            +6];/*gstate*/
   Ipp16s   vecLPCFltrCoeffs[10                  +6];/*apf*/
   Ipp16s   pstA[20                 +4];
   Ipp16s   d_buff[239+2            +7];
   Ipp16s   sst_buff[239+IDIM+1+2   +1];
   Ipp16s   sttmp[4*IDIM            +4];
   Ipp16s   nlssttmp[4              +4];
   Ipp16s   etpast_buff[140+IDIM    +7];/* G728I coder parameter*/

   own_G728_Obj_t    objPrm;
   const Ipp16s *pGq;
   const Ipp16s *pNgq;
   const Ipp16s *pCodebookGain;
   IppsSynthesisFilterState_G728_16s   *syntState;
   IppsPostFilterState_G728_16s        *stpMem;
   IppsWinHybridState_G728_16s         *rexpMem;
   IppsWinHybridState_G728_16s         *rexplgMem;
   IppsPostFilterAdapterState_G728     *postFltAdapterMem;
   Ipp16s        pst;
   Ipp16s        illcond;
   Ipp16s        illcondg;
   Ipp16s        illcondp;
   Ipp16s        scaleSyntFltrCoeffs;/*nlsatmp*/
   Ipp16s        scaleLGPredictorCoeffs;/*nlsgptmp*/
   Ipp16s        scaleLPCFltrCoeffs;/*nlsapf*/
   Ipp16s        rc1;
   Ipp16s        ip;
   Ipp32s        kp1;
   Ipp16s        gl;
   Ipp16s        glb;
   Ipp16s        scalefil;
   /* G728I coder parameters*/
   Ipp16s        ferror;                /* Frame erasure indicator*/
   Ipp16s        adcount;               /* G728 adaptation cycle counter (2.5 ms)*/
   Ipp16s        afterfe;               /* Counter for gain clipping after FE (2.5 ms)*/
   Ipp16s        fecount;               /* Lenght of current frame erasure (2.5 ms)*/
   Ipp16s        fedelay;               /* Pitch (KP) stored at beginning of FE*/
   Ipp16s        fescale;               /* etpast scaling factor for frame erasures*/
   Ipp16s        nlsfescale;            /* NLS for fescale*/
   Ipp32s        ogaindb;               /* Old prediction gain in dB*/
   Ipp16s        voiced;                /* Voiced/Unvoiced flag*/
   Ipp16s        avmag;                 /* Average magnitude of past 8 excitation vector*/
   Ipp16s        nlsavmag;              /* NLS for avmag*/
   Ipp16s        seed;
   Ipp16s        pTab;
};

/* basics operations */

__INLINE short ExtractHigh(int x);
__INLINE short Abs_16s(short x);
__INLINE int Abs_32s(int x);
__INLINE short Negate_16s(short x);
__INLINE int Negate_32s(int x);
__INLINE short Cnvrt_32s16s(int x);
__INLINE short Cnvrt_NR_32s16s(int x);
__INLINE int Cnvrt_64s32s(__INT64 z);
__INLINE int Sub_32s(int x,int y);
__INLINE short Sub_16s(short x, short y);
__INLINE short Add_16s(short x, short y);
__INLINE int Add_32s(int x, int y);
__INLINE short ShiftL_16s(short var1, short var2);
__INLINE int ShiftL_32s(int x, short n);

__INLINE short ExtractHigh(int x){
   return ((short)(x >> 16));
}
__INLINE short Abs_16s(short x){
   if(x<0){
      if(IPP_MIN_16S == x) return IPP_MAX_16S;
      x = (short)-x;
   }
   return x;
}
__INLINE int Abs_32s(int x){
   if(x<0){
      if(IPP_MIN_32S == x) return IPP_MAX_32S;
      x = -x;
   }
   return x;
}
__INLINE short Cnvrt_32s16s(int x){
   if (IPP_MAX_16S < x) return IPP_MAX_16S;
   else if (IPP_MIN_16S > x) return IPP_MIN_16S;
   return (short)(x);
}
__INLINE short Cnvrt_NR_32s16s(int x) {
   short s = IPP_MAX_16S;
   if(x<(int)0x7fff8000) s = (x+0x8000)>>16;
   return s;
}
__INLINE int Cnvrt_64s32s(__INT64 z) {
   if(IPP_MAX_32S < z) return IPP_MAX_32S;
   else if(IPP_MIN_32S > z) return IPP_MIN_32S;
   return (int)z;
}
__INLINE int Sub_32s(int x,int y){
   return Cnvrt_64s32s((__INT64)x - y);
}
__INLINE short Sub_16s(short x, short y) {
   int z = x - y;
   if (z>IPP_MAX_16S) return IPP_MAX_16S;
   else if(z<IPP_MIN_16S)return IPP_MIN_16S;
   return z;
}
__INLINE short Add_16s(short x, short y) {
   int z = x + y;
   if (z>IPP_MAX_16S) return IPP_MAX_16S;
   else if(z<IPP_MIN_16S)return IPP_MIN_16S;
   return z;
}
__INLINE int Add_32s(int x, int y) {
   Ipp64s z = (Ipp64s)x + y;
   if (z>IPP_MAX_32S) return IPP_MAX_32S;
   else if(z<IPP_MIN_32S)return IPP_MIN_32S;
   return (int)z;
}
__INLINE short Negate_16s(short x) {
   if(IPP_MIN_16S == x)
      return IPP_MAX_16S;
   return (short)-x;
}
__INLINE int Negate_32s(int x) {
   if(IPP_MIN_32S == x)
      return IPP_MAX_32S;
   return (int)-x;
}
__INLINE short ShiftL_16s(short x, short n){
   for(; n>0; n--){
      if (x > (short)0x3FFF) return (IPP_MAX_16S);
      else if (x < (short)0xC000) return (IPP_MIN_16S);
      else x *= 2;
   }
   return (x);
}
__INLINE int ShiftL_32s(int x, short n){
   for(; n>0; n--){
      if (x > (int)0x3FFFFFFF) return (IPP_MAX_32S);
      else if (x < (int)0xC0000000) return (IPP_MIN_32S);
      else x *= 2;
   }
   return (x);
}
#endif /* _OWN_G728_H_*/

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品久久久久久综合日本欧美 | 一区二区成人在线| 国产三级精品在线| 精品福利在线导航| 欧美va在线播放| 日韩欧美美女一区二区三区| 91精品欧美福利在线观看| 在线观看免费成人| 欧美日韩精品一区二区三区蜜桃| 91成人在线免费观看| 色综合久久天天| 色噜噜狠狠成人中文综合| 色综合久久综合网欧美综合网| 色哟哟在线观看一区二区三区| 色婷婷精品大在线视频| 欧美亚洲动漫另类| 欧美视频一区在线观看| 欧美日韩视频不卡| 日韩一区二区不卡| 欧美精品一区二区三区一线天视频| 精品国产麻豆免费人成网站| 欧美精品一区二区高清在线观看| 久久久久久久综合日本| 日本一区二区在线不卡| **欧美大码日韩| 亚洲高清免费在线| 久久国产精品99久久人人澡| 国产乱码一区二区三区| 91香蕉视频mp4| 欧美美女bb生活片| 日韩精品一区二区三区视频播放| 久久综合九色综合欧美亚洲| 国产精品亲子伦对白| 亚洲乱码国产乱码精品精小说| 亚洲超碰精品一区二区| 激情综合五月婷婷| 91色乱码一区二区三区| 欧美视频在线观看一区| 久久在线免费观看| 国产精品久久毛片a| 亚洲成人免费电影| 狠狠色丁香婷综合久久| 97国产一区二区| 欧美乱妇20p| 国产欧美一区二区精品性| 亚洲摸摸操操av| 日本不卡一区二区| 成人18视频在线播放| 欧美精品日韩综合在线| 国产亚洲污的网站| 亚洲高清免费观看高清完整版在线观看 | 精品国产乱码久久久久久浪潮| 日韩欧美国产一二三区| 中文字幕欧美三区| 爽好久久久欧美精品| 福利一区福利二区| 欧美一区二区视频免费观看| 国产精品久久影院| 久久精品久久综合| 日本韩国一区二区| 国产精品色婷婷久久58| 免费的成人av| 欧美特级限制片免费在线观看| 久久久99久久| 蜜臀久久99精品久久久画质超高清 | 一区二区三区在线看| 美日韩一区二区三区| 欧美优质美女网站| 国产精品成人免费在线| 九九精品一区二区| 91精品久久久久久久91蜜桃| 亚洲女子a中天字幕| 国产精品亚洲第一| 日韩一区和二区| 亚洲成人福利片| 91在线免费播放| 日韩女优毛片在线| 亚洲国产精品视频| 国产精品亚洲视频| 欧美一区二区三区日韩视频| 日韩欧美国产综合一区 | 中文字幕 久热精品 视频在线| 午夜日韩在线电影| 国产高清精品在线| 日韩精品一区二区三区视频| 亚洲综合成人在线视频| 国产精品自拍三区| 欧美精品黑人性xxxx| 亚洲日本在线a| 国产成人在线观看免费网站| 91精品久久久久久久久99蜜臂| 国产精品美女久久久久aⅴ国产馆 国产精品美女久久久久av爽李琼 国产精品美女久久久久高潮 | 五月开心婷婷久久| 97精品久久久午夜一区二区三区 | 91精品国产综合久久福利软件 | 青青草伊人久久| 日本精品视频一区二区| 中文幕一区二区三区久久蜜桃| 麻豆91精品91久久久的内涵| 欧美日韩一区不卡| 亚洲精品美国一| 大胆亚洲人体视频| 欧美精品电影在线播放| 日本一区中文字幕| 欧美日本高清视频在线观看| 一区二区三区高清在线| www.综合网.com| 国产精品―色哟哟| 成人激情小说乱人伦| 国产片一区二区| 国产一区二区按摩在线观看| 国产日产欧美一区二区三区| 国产综合久久久久影院| 日韩欧美国产成人一区二区| 青青草国产精品97视觉盛宴| 欧美一区二区三区免费观看视频| 亚洲一区二区三区三| 欧美性一二三区| 一区二区三区中文字幕| 欧美日韩免费观看一区三区| 亚洲福利一区二区| 欧美精品v国产精品v日韩精品| 日本免费新一区视频| 欧美一级高清大全免费观看| 日本不卡1234视频| 日韩精品中午字幕| 精品在线免费观看| 国产日韩亚洲欧美综合| 粉嫩绯色av一区二区在线观看| 国产精品欧美久久久久无广告| 成人免费高清视频在线观看| 国产精品国产三级国产专播品爱网| www.av精品| 亚洲精品福利视频网站| 在线观看av不卡| 爽爽淫人综合网网站| 日韩欧美国产高清| 国v精品久久久网| 最新国产成人在线观看| 欧美视频一区二| 一区二区理论电影在线观看| 欧美一级久久久| 国产电影一区在线| 亚洲视频香蕉人妖| 欧美日韩国产综合一区二区三区| 美国一区二区三区在线播放| 精品国产3级a| 99国产一区二区三精品乱码| 亚洲超丰满肉感bbw| 欧美一区午夜精品| 蜜臀久久久久久久| 国产精品无人区| 色一区在线观看| 麻豆精品一区二区综合av| 国产校园另类小说区| av在线免费不卡| 亚洲一区在线视频观看| 国产日韩在线不卡| 欧美在线不卡视频| 国产一区二区伦理| 亚洲精品成人a在线观看| 日韩区在线观看| gogo大胆日本视频一区| 免费视频最近日韩| 中文字幕亚洲综合久久菠萝蜜| 欧美精品电影在线播放| 国产黑丝在线一区二区三区| 一区二区三区不卡视频| 91精品免费在线| 国产一区二区网址| 日韩国产在线观看一区| 欧美激情一区二区在线| 欧美日韩你懂的| 成人一区在线观看| 亚洲成a人片综合在线| 日韩一区二区精品葵司在线| 在线观看免费视频综合| 国产精品自拍三区| 一区二区三区视频在线看| 欧美电影免费观看高清完整版在 | 久久久五月婷婷| 欧美日韩国产色站一区二区三区| 懂色av一区二区三区免费观看| 午夜视频在线观看一区| 欧美高清在线视频| 欧美成人a在线| 在线观看视频91| 国产精品1024| 亚洲成av人影院| 亚洲美女电影在线| 久久这里只精品最新地址| 欧美日本视频在线| 一本大道av伊人久久综合| 国产精品一区一区| 奇米777欧美一区二区| 亚洲精品视频在线观看网站| 国产午夜亚洲精品羞羞网站| 日韩视频一区二区三区| 欧美日韩成人高清| 色视频欧美一区二区三区|