![]() |
CI130X SDK API手册
2.2.0
本手册用于描述CI130X SDK各个组件和驱动API
|
结构体 | |
| struct | _HuffInfo |
| struct | _SBRHeader |
| struct | _SBRGrid |
| struct | _SBRFreq |
| struct | _SBRChan |
| struct | _PSInfoSBR |
宏定义 | |
| #define | ASSERT(x) /* do nothing */ |
| #define | MAX(a, b) ((a) > (b) ? (a) : (b)) |
| #define | MIN(a, b) ((a) < (b) ? (a) : (b)) |
| #define | NUM_TIME_SLOTS 16 |
| #define | SAMPLES_PER_SLOT 2 /* RATE in spec */ |
| #define | NUM_SAMPLE_RATES_SBR 9 /* downsampled (single-rate) mode unsupported, so only use Fs_sbr >= 16 kHz */ |
| #define | MAX_NUM_ENV 5 |
| #define | MAX_NUM_NOISE_FLOORS 2 |
| #define | MAX_NUM_NOISE_FLOOR_BANDS 5 /* max Nq, see 4.6.18.3.6 */ |
| #define | MAX_NUM_PATCHES 5 |
| #define | MAX_NUM_SMOOTH_COEFS 5 |
| #define | HF_GEN 8 |
| #define | HF_ADJ 2 |
| #define | MAX_QMF_BANDS 48 /* max QMF subbands covered by SBR (4.6.18.3.6) */ |
| #define | FBITS_IN_QMFA 14 |
| #define | FBITS_LOST_QMFA (1 + 2 + 3 + 2 + 1) /* 1 from cTab, 2 in premul, 3 in FFT, 2 in postmul, 1 for implicit scaling by 2.0 */ |
| #define | FBITS_OUT_QMFA (FBITS_IN_QMFA - FBITS_LOST_QMFA) |
| #define | MIN_GBITS_IN_QMFS 2 |
| #define | FBITS_IN_QMFS FBITS_OUT_QMFA |
| #define | FBITS_LOST_DCT4_64 (2 + 3 + 2) /* 2 in premul, 3 in FFT, 2 in postmul */ |
| #define | FBITS_OUT_DQ_ENV 29 /* dequantized env scalefactors are Q(29 - envDataDequantScale) */ |
| #define | FBITS_OUT_DQ_NOISE 24 /* range of Q_orig = [2^-24, 2^6] */ |
| #define | NOISE_FLOOR_OFFSET 6 |
| #define | FBITS_GLIM_BOOST 24 |
| #define | FBITS_QLIM_BOOST 14 |
| #define | MAX_HUFF_BITS 20 |
| #define | NUM_QMF_DELAY_BUFS 10 |
| #define | DELAY_SAMPS_QMFA (NUM_QMF_DELAY_BUFS * 32) |
| #define | DELAY_SAMPS_QMFS (NUM_QMF_DELAY_BUFS * 128) |
| #define | FFT32C STATNAME(FFT32C) |
| #define | CalcFreqTables STATNAME(CalcFreqTables) |
| #define | AdjustHighFreq STATNAME(AdjustHighFreq) |
| #define | GenerateHighFreq STATNAME(GenerateHighFreq) |
| #define | DecodeSBREnvelope STATNAME(DecodeSBREnvelope) |
| #define | DecodeSBRNoise STATNAME(DecodeSBRNoise) |
| #define | UncoupleSBREnvelope STATNAME(UncoupleSBREnvelope) |
| #define | UncoupleSBRNoise STATNAME(UncoupleSBRNoise) |
| #define | InvRNormalized STATNAME(InvRNormalized) |
| #define | RatioPowInv STATNAME(RatioPowInv) |
| #define | SqrtFix STATNAME(SqrtFix) |
| #define | QMFAnalysis STATNAME(QMFAnalysis) |
| #define | QMFSynthesis STATNAME(QMFSynthesis) |
| #define | GetSampRateIdx STATNAME(GetSampRateIdx) |
| #define | UnpackSBRHeader STATNAME(UnpackSBRHeader) |
| #define | UnpackSBRSingleChannel STATNAME(UnpackSBRSingleChannel) |
| #define | UnpackSBRChannelPair STATNAME(UnpackSBRChannelPair) |
| #define | CVKernel1 STATNAME(CVKernel1) |
| #define | CVKernel2 STATNAME(CVKernel2) |
| #define | QMFAnalysisConv STATNAME(QMFAnalysisConv) |
| #define | QMFSynthesisConv STATNAME(QMFSynthesisConv) |
| #define | k0Tab STATNAME(k0Tab) |
| #define | k2Tab STATNAME(k2Tab) |
| #define | goalSBTab STATNAME(goalSBTab) |
| #define | huffTabSBR STATNAME(huffTabSBR) |
| #define | huffTabSBRInfo STATNAME(huffTabSBRInfo) |
| #define | log2Tab STATNAME(log2Tab) |
| #define | noiseTab STATNAME(noiseTab) |
| #define | cTabA STATNAME(cTabA) |
| #define | cTabS STATNAME(cTabS) |
| #define | CLIP_2N_SHIFT30(y, n) |
| #define | CLIP_2N(y, n) |
类型定义 | |
| typedef struct _HuffInfo | HuffInfo |
| typedef struct _SBRHeader | SBRHeader |
| typedef struct _SBRGrid | SBRGrid |
| typedef struct _SBRFreq | SBRFreq |
| typedef struct _SBRChan | SBRChan |
| typedef struct _PSInfoSBR | PSInfoSBR |
枚举 | |
| enum | { SBR_GRID_FIXFIX = 0, SBR_GRID_FIXVAR = 1, SBR_GRID_VARFIX = 2, SBR_GRID_VARVAR = 3 } |
| enum | { HuffTabSBR_tEnv15 = 0, HuffTabSBR_fEnv15 = 1, HuffTabSBR_tEnv15b = 2, HuffTabSBR_fEnv15b = 3, HuffTabSBR_tEnv30 = 4, HuffTabSBR_fEnv30 = 5, HuffTabSBR_tEnv30b = 6, HuffTabSBR_fEnv30b = 7, HuffTabSBR_tNoise30 = 8, HuffTabSBR_fNoise30 = 5, HuffTabSBR_tNoise30b = 9, HuffTabSBR_fNoise30b = 7 } |
函数 | |
| void STATNAME() | FFT32C (int *x) |
| int STATNAME() | CalcFreqTables (SBRHeader *sbrHdr, SBRFreq *sbrFreq, int sampRateIdx) |
| void STATNAME() | AdjustHighFreq (PSInfoSBR *psi, SBRHeader *sbrHdr, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChan, int ch) |
| void STATNAME() | GenerateHighFreq (PSInfoSBR *psi, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChan, int ch) |
| void STATNAME() | DecodeSBREnvelope (BitStreamInfo *bsi, PSInfoSBR *psi, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChan, int ch) |
| void STATNAME() | DecodeSBRNoise (BitStreamInfo *bsi, PSInfoSBR *psi, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChan, int ch) |
| void STATNAME() | UncoupleSBREnvelope (PSInfoSBR *psi, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChanR) |
| void STATNAME() | UncoupleSBRNoise (PSInfoSBR *psi, SBRGrid *sbrGrid, SBRFreq *sbrFreq, SBRChan *sbrChanR) |
| int STATNAME() | InvRNormalized (int r) |
| int STATNAME() | RatioPowInv (int a, int b, int c) |
| int STATNAME() | SqrtFix (int x, int fBitsIn, int *fBitsOut) |
| int STATNAME() | QMFAnalysis (int *inbuf, int *delay, int *XBuf, int fBitsIn, int *delayIdx, int qmfaBands) |
| void STATNAME() | QMFSynthesis (int *inbuf, int *delay, int *delayIdx, int qmfsBands, short *outbuf, int nChans) |
| int STATNAME() | GetSampRateIdx (int sampRate) |
| int STATNAME() | UnpackSBRHeader (BitStreamInfo *bsi, SBRHeader *sbrHdr) |
| void STATNAME() | UnpackSBRSingleChannel (BitStreamInfo *bsi, PSInfoSBR *psi, int chOut) |
| void STATNAME() | UnpackSBRChannelPair (BitStreamInfo *bsi, PSInfoSBR *psi, int chOut) |
| const unsigned char | STATNAME (k0Tab) [9][16] |
| const unsigned char | STATNAME (k2Tab) [9][14] |
| const unsigned char | STATNAME (goalSBTab) [9] |
| const HuffInfo | STATNAME (huffTabSBRInfo) [10] |
| const signed short | STATNAME (huffTabSBR) [604] |
| const int | STATNAME (log2Tab) [65] |
| const int | STATNAME (noiseTab) [512 *2] |
| const int | STATNAME (cTabA) [165] |
| const int | STATNAME (cTabS) [640] |
| struct _SBRHeader |
| struct _SBRGrid |
| struct _SBRFreq |
| struct _SBRChan |
| struct _PSInfoSBR |
| 成员变量 | ||
|---|---|---|
| int | couplingFlag | |
| int | crcCheckWord | |
| unsigned char | dataExtra | |
| int | delayIdxQMFA[AAC_MAX_NCHANS] | |
| int | delayIdxQMFS[AAC_MAX_NCHANS] | |
| int | delayQMFA[AAC_MAX_NCHANS][(10 *32)] | |
| int | delayQMFS[AAC_MAX_NCHANS][(10 *128)] | |
| int | eCurr[48] | |
| unsigned char | eCurrExp[48] | |
| unsigned char | eCurrExpMax | |
| int | envBand | |
| int | envDataDequant[MAX_NCHANS_ELEM][5][48] | |
| signed char | envDataDequantScale[MAX_NCHANS_ELEM][5] | |
| int | eOMGainMax | |
| unsigned char | extendedDataPresent | |
| int | extendedDataSize | |
| int | frameCount | |
| int | gainMax | |
| int | gainMaxFBits | |
| int | gFiltLast[48] | |
| int | gLimBoost[48] | |
| int | gLimBuf[48] | |
| int | gLimFbits[48] | |
| int | highBand | |
| signed char | la | |
| int | noiseDataDequant[MAX_NCHANS_ELEM][2][5] | |
| int | noiseFloorBand | |
| int | qFiltLast[48] | |
| int | qmLimBoost[48] | |
| int | qmLimBuf[48] | |
| int | qp1Inv | |
| int | qqp1Inv | |
| unsigned char | resBitsData | |
| int | sampRateIdx | |
| int | sBand | |
| SBRChan | sbrChan[AAC_MAX_NCHANS] | |
| SBRFreq | sbrFreq[AAC_MAX_NCHANS] | |
| SBRGrid | sbrGrid[AAC_MAX_NCHANS] | |
| SBRHeader | sbrHdr[AAC_MAX_NCHANS] | |
| int | sMapped | |
| int | smBoost[48] | |
| int | smBuf[48] | |
| int | sumECurrGLim | |
| int | sumEOrigMapped | |
| int | sumQM | |
| int | sumSM | |
| int | XBuf[32+8][64][2] | |
| int | XBufDelay[AAC_MAX_NCHANS][8][64][2] | |
| #define AdjustHighFreq STATNAME(AdjustHighFreq) |
| #define ASSERT | ( | x | ) | /* do nothing */ |
| #define CalcFreqTables STATNAME(CalcFreqTables) |
| #define CLIP_2N | ( | y, | |
| n | |||
| ) |
| #define CLIP_2N_SHIFT30 | ( | y, | |
| n | |||
| ) |
| #define cTabA STATNAME(cTabA) |
| #define cTabS STATNAME(cTabS) |
| #define CVKernel1 STATNAME(CVKernel1) |
| #define CVKernel2 STATNAME(CVKernel2) |
| #define DecodeSBREnvelope STATNAME(DecodeSBREnvelope) |
| #define DecodeSBRNoise STATNAME(DecodeSBRNoise) |
| #define DELAY_SAMPS_QMFA (NUM_QMF_DELAY_BUFS * 32) |
| #define DELAY_SAMPS_QMFS (NUM_QMF_DELAY_BUFS * 128) |
| #define FBITS_GLIM_BOOST 24 |
| #define FBITS_IN_QMFA 14 |
| #define FBITS_IN_QMFS FBITS_OUT_QMFA |
| #define FBITS_LOST_DCT4_64 (2 + 3 + 2) /* 2 in premul, 3 in FFT, 2 in postmul */ |
| #define FBITS_LOST_QMFA (1 + 2 + 3 + 2 + 1) /* 1 from cTab, 2 in premul, 3 in FFT, 2 in postmul, 1 for implicit scaling by 2.0 */ |
| #define FBITS_OUT_DQ_ENV 29 /* dequantized env scalefactors are Q(29 - envDataDequantScale) */ |
| #define FBITS_OUT_DQ_NOISE 24 /* range of Q_orig = [2^-24, 2^6] */ |
| #define FBITS_OUT_QMFA (FBITS_IN_QMFA - FBITS_LOST_QMFA) |
| #define FBITS_QLIM_BOOST 14 |
| #define FFT32C STATNAME(FFT32C) |
| #define GenerateHighFreq STATNAME(GenerateHighFreq) |
| #define GetSampRateIdx STATNAME(GetSampRateIdx) |
| #define goalSBTab STATNAME(goalSBTab) |
| #define HF_ADJ 2 |
| #define HF_GEN 8 |
| #define huffTabSBR STATNAME(huffTabSBR) |
| #define huffTabSBRInfo STATNAME(huffTabSBRInfo) |
| #define InvRNormalized STATNAME(InvRNormalized) |
| #define k0Tab STATNAME(k0Tab) |
| #define k2Tab STATNAME(k2Tab) |
| #define log2Tab STATNAME(log2Tab) |
| #define MAX | ( | a, | |
| b | |||
| ) | ((a) > (b) ? (a) : (b)) |
| #define MAX_HUFF_BITS 20 |
| #define MAX_NUM_ENV 5 |
| #define MAX_NUM_NOISE_FLOOR_BANDS 5 /* max Nq, see 4.6.18.3.6 */ |
| #define MAX_NUM_NOISE_FLOORS 2 |
| #define MAX_NUM_PATCHES 5 |
| #define MAX_NUM_SMOOTH_COEFS 5 |
| #define MAX_QMF_BANDS 48 /* max QMF subbands covered by SBR (4.6.18.3.6) */ |
| #define MIN | ( | a, | |
| b | |||
| ) | ((a) < (b) ? (a) : (b)) |
| #define MIN_GBITS_IN_QMFS 2 |
| #define NOISE_FLOOR_OFFSET 6 |
| #define noiseTab STATNAME(noiseTab) |
| #define NUM_QMF_DELAY_BUFS 10 |
| #define NUM_SAMPLE_RATES_SBR 9 /* downsampled (single-rate) mode unsupported, so only use Fs_sbr >= 16 kHz */ |
| #define NUM_TIME_SLOTS 16 |
| #define QMFAnalysis STATNAME(QMFAnalysis) |
| #define QMFAnalysisConv STATNAME(QMFAnalysisConv) |
| #define QMFSynthesis STATNAME(QMFSynthesis) |
| #define QMFSynthesisConv STATNAME(QMFSynthesisConv) |
| #define RatioPowInv STATNAME(RatioPowInv) |
| #define SAMPLES_PER_SLOT 2 /* RATE in spec */ |
| #define SqrtFix STATNAME(SqrtFix) |
| #define UncoupleSBREnvelope STATNAME(UncoupleSBREnvelope) |
| #define UncoupleSBRNoise STATNAME(UncoupleSBRNoise) |
| #define UnpackSBRChannelPair STATNAME(UnpackSBRChannelPair) |
| #define UnpackSBRHeader STATNAME(UnpackSBRHeader) |
| #define UnpackSBRSingleChannel STATNAME(UnpackSBRSingleChannel) |
| typedef struct _PSInfoSBR PSInfoSBR |
| typedef struct _SBRHeader SBRHeader |
| anonymous enum |
| anonymous enum |
| void STATNAME() AdjustHighFreq | ( | PSInfoSBR * | psi, |
| SBRHeader * | sbrHdr, | ||
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChan, | ||
| int | ch | ||
| ) |
| void STATNAME() DecodeSBREnvelope | ( | BitStreamInfo * | bsi, |
| PSInfoSBR * | psi, | ||
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChan, | ||
| int | ch | ||
| ) |
| void STATNAME() DecodeSBRNoise | ( | BitStreamInfo * | bsi, |
| PSInfoSBR * | psi, | ||
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChan, | ||
| int | ch | ||
| ) |
| void STATNAME() FFT32C | ( | int * | x | ) |
| void STATNAME() GenerateHighFreq | ( | PSInfoSBR * | psi, |
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChan, | ||
| int | ch | ||
| ) |
| int STATNAME() GetSampRateIdx | ( | int | sampRate | ) |
| int STATNAME() InvRNormalized | ( | int | r | ) |
| int STATNAME() QMFAnalysis | ( | int * | inbuf, |
| int * | delay, | ||
| int * | XBuf, | ||
| int | fBitsIn, | ||
| int * | delayIdx, | ||
| int | qmfaBands | ||
| ) |
| void STATNAME() QMFSynthesis | ( | int * | inbuf, |
| int * | delay, | ||
| int * | delayIdx, | ||
| int | qmfsBands, | ||
| short * | outbuf, | ||
| int | nChans | ||
| ) |
| int STATNAME() RatioPowInv | ( | int | a, |
| int | b, | ||
| int | c | ||
| ) |
| int STATNAME() SqrtFix | ( | int | x, |
| int | fBitsIn, | ||
| int * | fBitsOut | ||
| ) |
| const unsigned char STATNAME | ( | k0Tab | ) |
| const unsigned char STATNAME | ( | k2Tab | ) |
| const unsigned char STATNAME | ( | goalSBTab | ) |
| const HuffInfo STATNAME | ( | huffTabSBRInfo | ) |
| const signed short STATNAME | ( | huffTabSBR | ) |
| const int STATNAME | ( | log2Tab | ) |
| const int STATNAME | ( | noiseTab | ) |
| const int STATNAME | ( | cTabA | ) |
| const int STATNAME | ( | cTabS | ) |
| void STATNAME() UncoupleSBREnvelope | ( | PSInfoSBR * | psi, |
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChanR | ||
| ) |
| void STATNAME() UncoupleSBRNoise | ( | PSInfoSBR * | psi, |
| SBRGrid * | sbrGrid, | ||
| SBRFreq * | sbrFreq, | ||
| SBRChan * | sbrChanR | ||
| ) |
| void STATNAME() UnpackSBRChannelPair | ( | BitStreamInfo * | bsi, |
| PSInfoSBR * | psi, | ||
| int | chOut | ||
| ) |
| int STATNAME() UnpackSBRHeader | ( | BitStreamInfo * | bsi, |
| SBRHeader * | sbrHdr | ||
| ) |
| void STATNAME() UnpackSBRSingleChannel | ( | BitStreamInfo * | bsi, |
| PSInfoSBR * | psi, | ||
| int | chOut | ||
| ) |
1.8.14