Commit 4a88a5d2 authored by Malenovsky, Vladimir's avatar Malenovsky, Vladimir
Browse files

test sr modifs

parent 14525296
Loading
Loading
Loading
Loading
Loading
+33 −0
Original line number Diff line number Diff line
@@ -2422,7 +2422,11 @@ static ivas_error decodeG192(
        }

        /* Head-tracking input simulation */
#ifdef FIX_VE
        if ( arg.enableHeadRotation )
#else
        if ( arg.enableHeadRotation || isSplitRend )
#endif
        {
            if ( headRotReader == NULL )
            {
@@ -2847,7 +2851,11 @@ static ivas_error decodeG192(
        }

        /* Head-tracking input simulation */
#ifdef FIX_VE
        if ( arg.enableHeadRotation )
#else
        if ( arg.enableHeadRotation || isSplitRend )
#endif
        {
            if ( headRotReader == NULL )
            {
@@ -3394,7 +3402,11 @@ static ivas_error decodeVoIP(
        }

        /* Head-tracking input simulation */
#ifdef FIX_VE
        if ( arg.enableHeadRotation )
#else
        if ( arg.enableHeadRotation || isSplitRend )
#endif
        {
            if ( headRotReader == NULL )
            {
@@ -4350,6 +4362,27 @@ static ivas_error restartDecoder(
        goto cleanup;
    }

#ifdef FIX_VE
    /*------------------------------------------------------------------------------------------*
     * Configure Split rendering
     *------------------------------------------------------------------------------------------*/

    if ( arg->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        if ( ( error = IVAS_DEC_EnableSplitRendering( hIvasDec ) ) != IVAS_ERR_OK )
        {
            fprintf( stderr, "\nSplit rendering configure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
            goto cleanup;
        }

        if ( ( error = IVAS_DEC_GetRenderFramesize( hIvasDec, &arg->renderFramesize ) ) != IVAS_ERR_OK )
        {
            fprintf( stderr, "\nConfigure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
            goto cleanup;
        }
    }
#endif

    if ( arg->voipMode )
    {
        if ( ( error = IVAS_DEC_EnableVoIP( hIvasDec, 60, arg->inputFormat ) ) != IVAS_ERR_OK )
+4 −0
Original line number Diff line number Diff line
@@ -171,8 +171,12 @@
#define FIX_2278_OOB_INDEXING_IN_CLOSED_LOOP_PIT_SEARCH /* FhG: fix oob indexing USAN complaint */
#define FIX_2287_MCT_MDCT_STEREO_DATA_MALLOC_SIZE       /* FhG: correct allocation size for STEREO_MDCT_DEC_DATA struct */

#define FIX_VE

/* #################### End BE switches ################################## */



/* #################### Start NON-BE switches ############################ */
/* any switch which is non-be wrt. TS 26.258 V3.0 */

+26 −6
Original line number Diff line number Diff line
@@ -320,12 +320,22 @@ ivas_error ivas_td_binaural_renderer_sf_splitBinaural(
        }
    }

#ifdef FIX_VE
    if ( pMultiBinPoseData->num_poses > 1 )
    {
#endif

        /* Save current head positions */
        for ( i = 0; i < st_ivas->hCombinedOrientationData->num_subframes; ++i )
        {
            originalHeadRot[i] = st_ivas->hCombinedOrientationData->Quaternions[i];
        }

#ifdef FIX_VE
    }
#endif


    original_subframes_rendered = st_ivas->hTcBuffer->subframes_rendered;
    original_slots_rendered = st_ivas->hTcBuffer->slots_rendered;
    origTdRendHandle = st_ivas->hBinRendererTd;
@@ -398,12 +408,22 @@ ivas_error ivas_td_binaural_renderer_sf_splitBinaural(
        mvr2r( output_local[i], output[i], nSamplesRendered );
    }

#ifdef FIX_VE
    if ( pMultiBinPoseData->num_poses > 1 )
    {
#endif

        /* Restore original head rotation */
        for ( i = 0; i < st_ivas->hCombinedOrientationData->num_subframes; ++i )
        {
            st_ivas->hCombinedOrientationData->Quaternions[i] = originalHeadRot[i];
        }

#ifdef FIX_VE
    }
#endif


    /* restore original td renderer handle */
    st_ivas->hBinRendererTd = origTdRendHandle;

+2 −0
Original line number Diff line number Diff line
@@ -530,10 +530,12 @@ ivas_error IVAS_DEC_Configure(
    hDecoderConfig->Opt_aeid_on = acousticEnvironmentId != 65535 ? TRUE : FALSE;
    hDecoderConfig->Opt_ObjEdit_on = (int16_t) objEditEnabled;

#ifndef FIX_VE
    if ( outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        hDecoderConfig->Opt_Headrotation = 1;
    }
#endif

    if ( renderFramesize == IVAS_RENDER_FRAMESIZE_UNKNOWN )
    {