Home | History | Annotate | Download | only in srce
      1 /******************************************************************************
      2  *
      3  *  Copyright (C) 2014 The Android Open Source Project
      4  *  Copyright 2003 - 2004 Open Interface North America, Inc. All rights reserved.
      5  *
      6  *  Licensed under the Apache License, Version 2.0 (the "License");
      7  *  you may not use this file except in compliance with the License.
      8  *  You may obtain a copy of the License at:
      9  *
     10  *  http://www.apache.org/licenses/LICENSE-2.0
     11  *
     12  *  Unless required by applicable law or agreed to in writing, software
     13  *  distributed under the License is distributed on an "AS IS" BASIS,
     14  *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     15  *  See the License for the specific language governing permissions and
     16  *  limitations under the License.
     17  *
     18  ******************************************************************************/
     19 
     20 /**********************************************************************************
     21   $Revision: #1 $
     22 ***********************************************************************************/
     23 
     24 /** @file
     25 @ingroup codec_internal
     26 */
     27 
     28 /**@addgroup codec_internal*/
     29 /**@{*/
     30 
     31 #include "oi_codec_sbc_private.h"
     32 
     33 const OI_CHAR* const OI_CODEC_SBC_FreqText[] =     { "SBC_FREQ_16000", "SBC_FREQ_32000", "SBC_FREQ_44100", "SBC_FREQ_48000" };
     34 const OI_CHAR* const OI_CODEC_SBC_ModeText[] =     { "SBC_MONO", "SBC_DUAL_CHANNEL", "SBC_STEREO", "SBC_JOINT_STEREO" };
     35 const OI_CHAR* const OI_CODEC_SBC_SubbandsText[] = { "SBC_SUBBANDS_4", "SBC_SUBBANDS_8" };
     36 const OI_CHAR* const OI_CODEC_SBC_BlocksText[] =   { "SBC_BLOCKS_4", "SBC_BLOCKS_8", "SBC_BLOCKS_12", "SBC_BLOCKS_16" };
     37 const OI_CHAR* const OI_CODEC_SBC_AllocText[] =    { "SBC_LOUDNESS", "SBC_SNR" };
     38 
     39 #ifdef OI_DEBUG
     40 void OI_CODEC_SBC_DumpConfig(OI_CODEC_SBC_FRAME_INFO *frameInfo)
     41 {
     42     printf("SBC configuration\n");
     43     printf("  enhanced:  %s\n", frameInfo->enhanced ? "TRUE" : "FALSE");
     44     printf("  frequency: %d\n", frameInfo->frequency);
     45     printf("  subbands:  %d\n", frameInfo->nrof_subbands);
     46     printf("  blocks:    %d\n", frameInfo->nrof_blocks);
     47     printf("  channels:  %d\n", frameInfo->nrof_channels);
     48     printf("  mode:      %s\n", OI_CODEC_SBC_ModeText[frameInfo->mode]);
     49     printf("  alloc:     %s\n", OI_CODEC_SBC_AllocText[frameInfo->alloc]);
     50     printf("  bitpool:   %d\n", frameInfo->bitpool);
     51 }
     52 #endif /* OI_DEBUG */
     53 
     54 /**@}*/
     55