Commit 6ed56a74 authored by Marek Szczerba's avatar Marek Szczerba
Browse files

Merge branch 'main' into 15-move-proximity-mixing-to-the-decoder

parents 80a53a4e fbcebe16
Loading
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -3721,8 +3721,9 @@ void ivas_sba_upmixer_renderer(
);

void ivas_sba_mix_matrix_determiner(
    Decoder_Struct *st_ivas,                                    /* i/o: IVAS decoder struct                     */
    float in_out[][L_FRAME48k],                                 /* i/o: transport/output audio channels         */
    SPAR_DEC_HANDLE hSpar,                                      /* i/o: SPAR decoder handle                     */
    float output[][L_FRAME48k],                                 /* i/o: transport/output audio channels         */
    const int16_t bfi,                                          /* i  : BFI flag                                */
    const int16_t nchan_remapped,                               /* i  : num channels after remapping of TCs     */
    const int16_t output_frame                                  /* i  : output frame length                     */
);
+3 −3
Original line number Diff line number Diff line
@@ -149,7 +149,7 @@

#define I15_IMPLEMENT_PROX_MIXING_FOR_ISM_DECODER       /* Implement proximity-based mixing in ISM decoder/renderer */
#define FIX_ADAP_STEFI_SHIFT                            /* Issue 89: fix bug in parameter shift of adaptive stereo filling */
#define SPAR_SCALING_HARMONIZATION                      /* issue 80: Changes to harmonize scaling in spar */
#define SPAR_SCALING_HARMONIZATION                      /* Issue 80: Changes to harmonize scaling in spar */


/* ################## End DEVELOPMENT switches ######################### */
+2 −0
Original line number Diff line number Diff line
@@ -1115,5 +1115,7 @@ ivas_error ivas_crend_process(
        mvr2r( pcm_tmp[i], output[i], output_frame );
    }

    wmops_sub_end();

    return IVAS_ERR_OK;
}
+1 −1
Original line number Diff line number Diff line
@@ -309,7 +309,7 @@ ivas_error ivas_dec(

            if ( st_ivas->sba_mode == SBA_MODE_SPAR && ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM ) )
            {
                ivas_sba_mix_matrix_determiner( st_ivas, output, nchan_remapped, output_frame );
                ivas_sba_mix_matrix_determiner( st_ivas->hSpar, output, st_ivas->bfi, nchan_remapped, output_frame );
            }
        }

+15 −28
Original line number Diff line number Diff line
@@ -511,29 +511,6 @@ ivas_error ivas_init_decoder_front(

    error = IVAS_ERR_OK;

#ifdef DEBUGGING
    st_ivas->noClipping = 0;
#endif

    /* Custom loudspeaker layout structure */
    st_ivas->hLsSetupCustom = NULL;

    /* TD renderer HRTF data structure */
    st_ivas->hHrtfTD = NULL;

    /* Head track data structure */
    st_ivas->hHeadTrackData = NULL;

    /* Renderer configuration structure */
    st_ivas->hRenderConfig = NULL;

    /* HRTF binauralization latency in ns */
    st_ivas->binaural_latency_ns = 0;

#ifdef DEBUGGING
    st_ivas->hDecoderConfig->force_rend = -1;
#endif

    /*-----------------------------------------------------------------*
     * Resets
     *-----------------------------------------------------------------*/
@@ -546,9 +523,16 @@ ivas_error ivas_init_decoder_front(
    st_ivas->mc_mode = MC_MODE_NONE;
    st_ivas->sba_mode = SBA_MODE_NONE;

    st_ivas->hLimiter = NULL;
    st_ivas->hoa_dec_mtx = NULL;
    st_ivas->sba_dirac_stereo_flag = 0;
    
    /* HRTF binauralization latency in ns */
    st_ivas->binaural_latency_ns = 0;

#ifdef DEBUGGING
    st_ivas->noClipping = 0;

    st_ivas->hDecoderConfig->force_rend = -1;
#endif

    /*-------------------------------------------------------------------*
     * Allocate and initialize Custom loudspeaker layout handle
@@ -700,6 +684,7 @@ ivas_error ivas_init_decoder(
        }
    }

#if 0
    /*-----------------------------------------------------------------*
     * Dummy pointers to decoder handles
     *-----------------------------------------------------------------*/
@@ -751,6 +736,7 @@ ivas_error ivas_init_decoder(
    st_ivas->hMonoDmxRenderer = NULL;   /* Mono downmix renderer */
    st_ivas->hHrtf = NULL;              /* Crend hrtf data */
    st_ivas->hCrend = NULL;             /* Crend renderer */
#endif

    /*-----------------------------------------------------------------*
     * Allocate and initalize SCE/CPE and other handles
@@ -1340,9 +1326,8 @@ ivas_error ivas_init_decoder(
     * Allocate and initialize limiter struct
     *-----------------------------------------------------------------*/

    {
    st_ivas->hLimiter = ivas_limiter_open( hDecoderConfig->nchan_out, output_Fs );
    }


    return error;
}
@@ -1555,11 +1540,13 @@ void ivas_initialize_handles_dec(
    st_ivas->hMonoDmxRenderer = NULL;
    st_ivas->hCrend = NULL;
    st_ivas->hHrtf = NULL;
    st_ivas->hoa_dec_mtx = NULL;

    st_ivas->hHeadTrackData = NULL;
    st_ivas->hHrtfTD = NULL;
    st_ivas->hLimiter = NULL;
    st_ivas->hLsSetupCustom = NULL;
    st_ivas->hRenderConfig = NULL;

    return;
}
Loading