videoeditorengine/mp3aacManipLib/AACGain/inc/tool2.h
changeset 0 951a5db380a0
equal deleted inserted replaced
-1:000000000000 0:951a5db380a0
       
     1 /*
       
     2 * Copyright (c) 2010 Ixonos Plc.
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - Initial contribution
       
    11 *
       
    12 * Contributors:
       
    13 * Ixonos Plc
       
    14 *
       
    15 * Description:
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 /**************************************************************************
       
    21   tool2.h - Interface to AAC decoding functions.
       
    22  
       
    23   Author(s): Juha Ojanpera
       
    24   Copyright (c) 2003-2004 by Nokia Research Center, Speech and Audio Systems.
       
    25   *************************************************************************/
       
    26 
       
    27 #ifndef    AAC_FUNC_H_
       
    28 #define AAC_FUNC_H_
       
    29 
       
    30 /*-- Project Headers. --*/
       
    31 #include "aacaud.h"
       
    32 #include "tool.h"
       
    33 
       
    34 /*
       
    35  * Sfb initialization. 
       
    36  */
       
    37 void
       
    38 AACSfbInfoInit(CSfb_Info *sfb, uint8 sIndex, uint8 is960);
       
    39 
       
    40 int32
       
    41 AACSampleRate(uint8 sampleRateIdx);
       
    42 
       
    43 
       
    44 /*
       
    45  * Control of channel configuration. 
       
    46  */
       
    47 int16
       
    48 CCChIndex(CMC_Info *mip, int16 cpe, int16 tag);
       
    49 
       
    50 int16
       
    51 ChIndex(int16 nch, int16 tag, int16 wnd, CMC_Info *mip);
       
    52 
       
    53 
       
    54 /*
       
    55  * AAC syntactic channel elements. 
       
    56  */
       
    57 int16 
       
    58 GetSCE(CAACAudDec *aac, TBitStream *bs, CMC_Info *mip, uint8 *gains, 
       
    59        uint32 *gainPos, uint32 bufBitOffset);
       
    60 
       
    61 int16 
       
    62 GetCPE(CAACAudDec *aac, TBitStream *bs, CMC_Info *mip, uint8 *gains, 
       
    63        uint32 *gainPos, uint32 bufBitOffset);
       
    64 
       
    65 int16 
       
    66 GetCCE(CAACAudDec *aac, TBitStream *bs, CMC_Info *mip, CCInfo **ccInfo);
       
    67 
       
    68 int16 
       
    69 GetICS(TBitStream *bs, TCh_Info *cip, uint8 *group, uint8 max_sfb, 
       
    70        uint8 *cb_map, int16 *quant, int16 global_gain, 
       
    71        int16 *factors);
       
    72 
       
    73 int16
       
    74 GetICSInfo(TBitStream *bs, CWindowInfo *winInfo, CLTP_Info *ltp_left, CLTP_Info *ltp_right);
       
    75 
       
    76 
       
    77 /*
       
    78  * Huffman decoding interfaces. 
       
    79  */
       
    80 uint32 
       
    81 GetHcb(Huffman_DecSfInfo *huf_info, TBitStream *bs);
       
    82 
       
    83 int16
       
    84 huf_sfac(TBitStream *bs, TCh_Info *cip, uint8 *group, uint8 *cb_map,
       
    85          int16 global_gain, int16 *factors, uint8 max_sfb);
       
    86 
       
    87 int16
       
    88 huf_spec(TBitStream *bs, CInfo *info, int16 nsect, uint8 *sect, 
       
    89          int16 *quant, Huffman_DecInfo **huf, uint8 parseOnly);
       
    90 
       
    91 
       
    92 /*
       
    93  * Global gain element extraction and storage.
       
    94  */
       
    95 int16
       
    96 GetSCEGain(CAACAudDec *aac, TBitStream *bs, uint8 *gains, 
       
    97            uint32 *gainPos, uint32 bufBitOffset);
       
    98 
       
    99 int16
       
   100 GetCPEGain(CAACAudDec *aac, TBitStream *bs, uint8 *gains, 
       
   101            uint32 *gainPos, uint32 bufBitOffset);
       
   102 
       
   103 #endif    /*-- AAC_FUNC_H_ --*/