Commit 813ea695 authored by Nicolas Roussin's avatar Nicolas Roussin
Browse files

Remove ifdefs.

parent 232d7922
Loading
Loading
Loading
Loading
Loading
+0 −18
Original line number Diff line number Diff line
@@ -1472,13 +1472,8 @@ static void ivas_dirac_dec_binaural_formulate_input_covariance_matrices_fx(
#ifdef NONBE_2157_IVAS_DIRAC_DEC_BINAURAL_FORMULATE_INPUT_COVARIANCE_MATRICES
    rsh0 = (Word16) ( ceil_log2( hSpatParamRendCom->subframe_nbslots[subframe] ) - 1 );
    rsh1 = (Word16) ( ceil_log2( BINAURAL_CHANNELS * hSpatParamRendCom->subframe_nbslots[subframe] ) - 1 );
#if 1
    exp0 = sub( 63, shl( q, 1 ) );
    exp1 = sub( 63, shl( q, 1 ) );
#else
    exp0 = add( sub( 63, shl( q, 1 ) ), rsh0 );
    exp1 = add( sub( 63, shl( q, 1 ) ), rsh1 );
#endif
#else
    exp = sub( 63, shl( q, 1 ) ); // exp for the energy (inRe_fx * inRe_fx + inIm_fx * inIm_fx) computed below
#endif
@@ -1493,13 +1488,8 @@ static void ivas_dirac_dec_binaural_formulate_input_covariance_matrices_fx(
                temp64 = W_mult0_32_32( inRe_fx[ch][slot][bin], inRe_fx[ch][slot][bin] );                  // 2q
                temp64 = W_add( temp64, W_mult0_32_32( inIm_fx[ch][slot][bin], inIm_fx[ch][slot][bin] ) ); // 2q
#ifdef NONBE_2157_IVAS_DIRAC_DEC_BINAURAL_FORMULATE_INPUT_COVARIANCE_MATRICES
#if 1
                hDiracDecBin->ChEne[ch][bin] = W_add( hDiracDecBin->ChEne[ch][bin], temp64 ); // 2q
                subFrameTotalEne[bin] = W_add( subFrameTotalEne[bin], temp64 );               // 2q
#else
                hDiracDecBin->ChEne[ch][bin] = W_add( hDiracDecBin->ChEne[ch][bin], W_shr( temp64, rsh0 ) ); // 2q - rsh0
                subFrameTotalEne[bin] = W_add( subFrameTotalEne[bin], W_shr( temp64, rsh1 ) );               // 2q - rsh1
#endif
                move64();
                move64();
#else
@@ -1516,11 +1506,7 @@ static void ivas_dirac_dec_binaural_formulate_input_covariance_matrices_fx(
            temp64 = W_mult0_32_32( inRe_fx[0][slot][bin], inRe_fx[1][slot][bin] );                  // 2q
            temp64 = W_add( temp64, W_mult0_32_32( inIm_fx[0][slot][bin], inIm_fx[1][slot][bin] ) ); // 2q
#ifdef NONBE_2157_IVAS_DIRAC_DEC_BINAURAL_FORMULATE_INPUT_COVARIANCE_MATRICES
#if 1
            hDiracDecBin->ChCrossRe[bin] = W_add( hDiracDecBin->ChCrossRe[bin], temp64 ); // 2q
#else
            hDiracDecBin->ChCrossRe[bin] = W_add( hDiracDecBin->ChCrossRe[bin], W_shr( temp64, rsh0 ) ); // 2q - rsh0
#endif
            move64();
#else
            exp1 = W_norm( temp64 );
@@ -1532,11 +1518,7 @@ static void ivas_dirac_dec_binaural_formulate_input_covariance_matrices_fx(
            temp64 = W_mult0_32_32( inRe_fx[0][slot][bin], inIm_fx[1][slot][bin] );                  // 2q
            temp64 = W_sub( temp64, W_mult0_32_32( inIm_fx[0][slot][bin], inRe_fx[1][slot][bin] ) ); // 2q
#ifdef NONBE_2157_IVAS_DIRAC_DEC_BINAURAL_FORMULATE_INPUT_COVARIANCE_MATRICES
#if 1
            hDiracDecBin->ChCrossIm[bin] = W_add( hDiracDecBin->ChCrossIm[bin], temp64 ); // 2q
#else
            hDiracDecBin->ChCrossIm[bin] = W_add( hDiracDecBin->ChCrossIm[bin], W_shr( temp64, rsh0 ) ); // 2q - rsh0
#endif
            move64();
#else
            exp1 = W_norm( temp64 );