Commit 0ec3087a authored by vaclav's avatar vaclav
Browse files
parents 46679e79 f41541c9
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1409,10 +1409,16 @@ typedef enum
#define SFX_SPAT_BIN_NUM_SUBSAMPLES             64
#define ITD_MEM_LEN                             (MAX_ITD + SFX_SPAT_BIN_SINC_M)
#define L_SUBFRAME5MS_48k                       (L_FRAME48k/4)
#ifdef FIX_337_TDREND_INTP
#define MAX_ANGULAR_STEP                        (1.0f)
#else
#define MAX_ANGULAR_STEP                        (15.0f)
#endif
#define MAX_ANGULAR_STEP_INV                    ( 1.0f / MAX_ANGULAR_STEP )
#define MAX_INTERPOLATION_STEPS                 12
#ifndef FIX_310_TD_REND_DELAY
#define BINAURAL_TD_LATENCY_S                   0.0f                        /* ITD fix removes TD renderer delay -- should be cleaned out */
#endif

/* ----- Enums - TD Renderer ----- */

+2 −1
Original line number Diff line number Diff line
@@ -150,9 +150,10 @@
#define HRTF_BINARY_FILE                                /* HRTF filters' binary file used for binaural rendering. */

#define FIX_197_CREND_INTERFACE 
#define FIX_FOR_TEST                                    /* allows tests to pass using old TD binary file, to be removed after merge*/
#define FIX_301_PLC                                     /* FhG: issue 301 - fix bug of missing update of overlap buffer for DFT-stereo PLC*/
#define FIX_337_TDREND_INTP                             /* Issue 337: TD renderer interpolation threshold set too low */

#define FIX_310_TD_REND_DELAY                           /* Adding HRTF delay being read from ROM/Binary file, fix rounding for delay compensation in renderer */

/* ################## End DEVELOPMENT switches ######################### */
/* clang-format on */
+12 −0
Original line number Diff line number Diff line
@@ -695,17 +695,29 @@ ivas_error ivas_binRenderer_open(
        {
            if ( hBinRenderer->ivas_format == MC_FORMAT )
            {
#ifdef HRTF_BINARY_FILE
                st_ivas->binaural_latency_ns = (int32_t) ( st_ivas->hHrtfFastConv->FASTCONV_HRIR_latency_s * 1000000000.f );
#else
                st_ivas->binaural_latency_ns = (int32_t) ( FASTCONV_HRIR_latency_s * 1000000000.f );
#endif
            }
            else
            {
#ifdef HRTF_BINARY_FILE
                st_ivas->binaural_latency_ns = (int32_t) ( st_ivas->hHrtfFastConv->FASTCONV_HOA3_latency_s * 1000000000.f );
#else
                st_ivas->binaural_latency_ns = (int32_t) ( FASTCONV_HOA3_latency_s * 1000000000.f );
#endif
            }
        }
        else
        {
            /* same value for MC or HOA both use MC BRIR*/
#ifdef HRTF_BINARY_FILE
            st_ivas->binaural_latency_ns = (int32_t) ( st_ivas->hHrtfFastConv->FASTCONV_BRIR_latency_s * 1000000000.f );
#else
            st_ivas->binaural_latency_ns = (int32_t) ( FASTCONV_BRIR_latency_s * 1000000000.f );
#endif
        }
#else
        if ( hBinRenderer->ivas_format == MC_FORMAT )
+4 −0
Original line number Diff line number Diff line
@@ -426,7 +426,11 @@ ivas_error ivas_rend_TDObjRendOpen(

    pTDRend->hBinRendererTd = hBinRendererTd;

#ifdef FIX_310_TD_REND_DELAY
    pTDRend->binaural_latency_ns = (int32_t) ( hBinRendererTd->HrFiltSet_p->latency_s * 1000000000.f );
#else
    pTDRend->binaural_latency_ns = (int32_t) ( BINAURAL_TD_LATENCY_S * 1000000000.f );
#endif

    return IVAS_ERR_OK;
}
+1 −1
Original line number Diff line number Diff line
@@ -341,7 +341,7 @@ ivas_error TDREND_MIX_AddSrc(
 * Allocate the B Spline HR Filter model.
 --------------------------------------------------------------------*/

static void BSplineModelEvalAlloc(
void BSplineModelEvalAlloc(
    ModelParams_t *model,  /* i  : Model parameters           */
    ModelEval_t *modelEval /* i/o: Model evaluation structure */
)
Loading