Commit ef2b80ef authored by TYAGIRIS's avatar TYAGIRIS
Browse files

build sanitizer fix, clang formatting fix

parent 478c21d2
Loading
Loading
Loading
Loading
Loading
+92 −3
Original line number Diff line number Diff line
@@ -286,7 +286,96 @@ void IVAS_DEC_Close(

    return;
}
#ifdef SPLIT_REND_WITH_HEAD_ROT
/*---------------------------------------------------------------------*
 * mapAudioConfig2DecAudoioConfig()
 *
 *
 *---------------------------------------------------------------------*/

static IVAS_DEC_AUDIO_CONFIG mapAudioConfig2DecAudoioConfig(
    const AUDIO_CONFIG audio_config )
{
    IVAS_DEC_AUDIO_CONFIG dec_audio_config;

    if ( audio_config == AUDIO_CONFIG_EXTERNAL ) /* external renderer */
    {
        dec_audio_config = IVAS_DEC_OUTPUT_EXT;
    }
    else if ( audio_config == AUDIO_CONFIG_MONO )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_MONO;
    }
    else if ( audio_config == AUDIO_CONFIG_STEREO )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_STEREO;
    }
    else if ( audio_config == AUDIO_CONFIG_5_1 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_5_1;
    }
    else if ( audio_config == AUDIO_CONFIG_7_1 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_7_1;
    }
    else if ( audio_config == AUDIO_CONFIG_5_1_2 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_5_1_2;
    }
    else if ( audio_config == AUDIO_CONFIG_5_1_4 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_5_1_4;
    }
    else if ( audio_config == AUDIO_CONFIG_7_1_4 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_7_1_4;
    }
    else if ( audio_config == AUDIO_CONFIG_LS_CUSTOM )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_LS_CUSTOM;
    }
    else if ( audio_config == AUDIO_CONFIG_FOA )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_FOA;
    }
    else if ( audio_config == AUDIO_CONFIG_HOA2 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_HOA2;
    }
    else if ( audio_config == AUDIO_CONFIG_HOA3 )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_HOA3;
    }
    else if ( audio_config == AUDIO_CONFIG_BINAURAL )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_BINAURAL;
    }
    else if ( audio_config == AUDIO_CONFIG_BINAURAL_ROOM_IR )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_BINAURAL_ROOM_IR;
    }
    else if ( audio_config == AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_BINAURAL_ROOM_REVERB;
    }
#ifdef SPLIT_REND_WITH_HEAD_ROT
    else if ( audio_config == AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_SPLIT_BINAURAL_CODED;
    }
    else if ( audio_config == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        dec_audio_config = IVAS_DEC_OUTPUT_SPLIT_BINAURAL_PCM;
    }
#endif
    else
    {
        dec_audio_config = IVAS_DEC_OUTPUT_UNKNOWN;
    }

    return dec_audio_config;
}
#endif

/*---------------------------------------------------------------------*
 * mapOutputFormat()
@@ -3262,10 +3351,10 @@ ivas_error IVAS_DEC_GetCldfbSamples(
    num_samples = 0;
    if ( st_ivas->splitBinRend.hCldfbDataOut != NULL )
    {
        *audio_config = st_ivas->splitBinRend.hCldfbDataOut->config;
        *audio_config = mapAudioConfig2DecAudoioConfig( st_ivas->splitBinRend.hCldfbDataOut->config );
        if ( st_ivas->splitBinRend.hCldfbDataOut->config != AUDIO_CONFIG_INVALID )
        {
            getAudioConfigNumChannels( st_ivas->splitBinRend.hCldfbDataOut->config, &num_chs );
            num_chs = audioCfg2channels( st_ivas->splitBinRend.hCldfbDataOut->config );
            maxBand = (int16_t) ( ( CLDFB_NO_CHANNELS_MAX * st_ivas->hDecoderConfig->output_Fs ) / 48000 );

            for ( slot_idx = 0; slot_idx < CLDFB_NO_COL_MAX; slot_idx++ )
@@ -3284,7 +3373,7 @@ ivas_error IVAS_DEC_GetCldfbSamples(
    }
    else
    {
        *audio_config = AUDIO_CONFIG_INVALID;
        *audio_config = IVAS_DEC_OUTPUT_UNKNOWN;
    }
    *nOutSamples = num_samples;
    return error;
+24 −30
Original line number Diff line number Diff line
@@ -101,13 +101,7 @@ static void ivas_dirac_dec_binaural_formulate_target_covariance_matrices( DIRAC_
static void ivas_dirac_dec_binaural_determine_processing_matrices( DIRAC_DEC_BIN_HANDLE hDiracDecBin, SPAT_PARAM_REND_COMMON_DATA_HANDLE hSpatParamRendCom, PARAMBIN_REND_CONFIG_HANDLE hConfig, const int16_t max_band_decorr, float Rmat[3][3], const int16_t isHeadtracked );

#ifdef SPLIT_REND_WITH_HEAD_ROT_PARAMBIN
static void ivas_dirac_dec_binaural_process_output( DIRAC_DEC_BIN_HANDLE hDiracDecBin, SPAT_PARAM_REND_COMMON_DATA_HANDLE hSpatParamRendCom, HANDLE_CLDFB_FILTER_BANK cldfbSynDec[MAX_OUTPUT_CHANNELS],
                                                    float *output_f[], float inRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float inIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX],
                                                    const int16_t max_band_decorr, const int16_t numInChannels, const int16_t processReverb, const int16_t subframe,
                                                    float outRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float outIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX],
                                                    float reverbRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float reverbIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX],
                                                    float decorrRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float decorrIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX],
                                                    const uint8_t recompute );
static void ivas_dirac_dec_binaural_process_output( DIRAC_DEC_BIN_HANDLE hDiracDecBin, SPAT_PARAM_REND_COMMON_DATA_HANDLE hSpatParamRendCom, HANDLE_CLDFB_FILTER_BANK cldfbSynDec[MAX_OUTPUT_CHANNELS], float *output_f[], float inRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float inIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], const int16_t max_band_decorr, const int16_t numInChannels, const int16_t processReverb, const int16_t subframe, float outRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float outIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float reverbRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float reverbIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float decorrRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float decorrIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], const uint8_t recompute );
#else
static void ivas_dirac_dec_binaural_process_output( DIRAC_DEC_BIN_HANDLE hDiracDecBin, SPAT_PARAM_REND_COMMON_DATA_HANDLE hSpatParamRendCom, HANDLE_CLDFB_FILTER_BANK cldfbSynDec[MAX_OUTPUT_CHANNELS], float *output_f[], float inRe[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], float inIm[][CLDFB_SLOTS_PER_SUBFRAME][CLDFB_NO_CHANNELS_MAX], const int16_t max_band_decorr, const int16_t numInChannels, const int16_t processReverb, const int16_t subframe );
#endif
+4 −4

File changed.

Contains only whitespace changes.

+1 −1

File changed.

Contains only whitespace changes.

+2 −2

File changed.

Contains only whitespace changes.