Commit 1b916d7c authored by multrus's avatar multrus
Browse files

[cleanup] accept NONBE_1894_OSBA_SCALING

parent 80e6f63e
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -5607,7 +5607,6 @@ ivas_error ivas_osba_render_sf(
    float *output_f[]                                           /* o  : rendered time signal                    */
);

#ifdef NONBE_1894_OSBA_SCALING
void ivas_osba_stereo_add_channels(
    float *tc_f[],                                              /* i  : transport channels                      */
    float *output_f[],                                          /* i/o: output channels                         */
@@ -5616,7 +5615,6 @@ void ivas_osba_stereo_add_channels(
    const int16_t nchan_ism,                                    /* i  : number of ISM channels                  */
    const int16_t n_samples_to_render                           /* i  : output frame length per channel         */
);
#endif

void ivas_osba_data_close(
    SBA_ISM_DATA_HANDLE *hSbaIsmData                            /* i/o: OSBA rendering handle                   */
+0 −1
Original line number Diff line number Diff line
@@ -159,7 +159,6 @@
#define FIX_1129_EXT_REND_OUTPUT_HIGH                   /* Philips: issue 1129: External renderer BINAURAL_ROOM_REVERB format output level too high compared to internal rendering output */
#define NONBE_1244_FIX_SWB_BWE_MEMORY                   /* VA: issue 1244: fix to SWB BWE memory in case of switching from FB coding - pending a review by Huawei */
#define FIX_1113_CLDFB_REND_IN_ISAR                     /* issue 1113: fix the use of CLDFB renderer in split-rendering at the external renderer */
#define NONBE_1894_OSBA_SCALING                         /* FhG: port OSBA scaling MRs (298,355,360) jointly */
#define NONBE_FIX_1141_OSBA_ROOM_RENDERING              /* FhG: Fix for issue 1141: render objects in OSBA decoder with room effect  */
#define NONBE_1360_LFE_DELAY                            /* Dlb: LFE delay alignment when rendering in CLDFB domain*/
#define NONBE_1229_FIX_ISM1_DPID                        /* Eri: issue 1229: fix bug causing ISM 1 to use default -dpid instead of the specified one */
+0 −11
Original line number Diff line number Diff line
@@ -1226,14 +1226,7 @@ ivas_error ivas_jbm_dec_render(
                ivas_ism_render_sf( st_ivas, st_ivas->renderer_type, p_output, *nSamplesRendered );

                /* add already rendered SBA part */
#ifdef NONBE_1894_OSBA_SCALING
                ivas_osba_stereo_add_channels( p_tc, p_output, 1.0f, nchan_out, st_ivas->nchan_ism, *nSamplesRendered );
#else
                for ( n = 0; n < nchan_out; n++ )
                {
                    v_add( p_output[n], p_tc[n + st_ivas->nchan_ism], p_output[n], *nSamplesRendered );
                }
#endif
            }
            else if ( st_ivas->renderer_type == RENDERER_OSBA_AMBI || st_ivas->renderer_type == RENDERER_OSBA_LS || st_ivas->renderer_type == RENDERER_BINAURAL_FASTCONV_ROOM )
            {
@@ -1265,12 +1258,10 @@ ivas_error ivas_jbm_dec_render(
        else if ( st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC || st_ivas->renderer_type == RENDERER_BINAURAL_PARAMETRIC_ROOM )
        {
            ivas_dirac_dec_binaural_render( st_ivas, nSamplesAskedLocal, nSamplesRendered, nSamplesAvailableNext, nchan_remapped, p_output );
#ifdef NONBE_1894_OSBA_SCALING
            for ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ )
            {
                v_multc( p_output[n], 2.0f, p_output[n], *nSamplesRendered );
            }
#endif
        }
        else
        {
@@ -1293,12 +1284,10 @@ ivas_error ivas_jbm_dec_render(
                    set_zero( p_output[n], *nSamplesRendered );
                }
            }
#ifdef NONBE_1894_OSBA_SCALING
            for ( n = 0; n < st_ivas->hDecoderConfig->nchan_out; n++ )
            {
                v_multc( p_output[n], 2.0f, p_output[n], *nSamplesRendered );
            }
#endif
        }
    }
    else if ( st_ivas->ivas_format == MC_FORMAT )
+0 −19
Original line number Diff line number Diff line
@@ -182,20 +182,10 @@ ivas_error ivas_osba_dirac_td_binaural_jbm(
                for ( b = 0; b < num_cldfb_bands; b++ )
                {
                    st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural[n][slot_idx_start + slot_idx][b] =
#ifndef NONBE_1894_OSBA_SCALING
                        ( 0.5f * st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural[n][slot_idx_start + slot_idx][b] ) +
                        ( 0.5f * Cldfb_RealBuffer[b] );
#else
                        st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_RealBuffer_Binaural[n][slot_idx_start + slot_idx][b] + Cldfb_RealBuffer[b];
#endif

                    st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural[n][slot_idx_start + slot_idx][b] =
#ifndef NONBE_1894_OSBA_SCALING
                        ( 0.5f * st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural[n][slot_idx_start + slot_idx][b] ) +
                        ( 0.5f * Cldfb_ImagBuffer[b] );
#else
                        st_ivas->hSplitBinRend->hMultiBinCldfbData->Cldfb_ImagBuffer_Binaural[n][slot_idx_start + slot_idx][b] + Cldfb_ImagBuffer[b];
#endif
                }
            }
        }
@@ -212,11 +202,7 @@ ivas_error ivas_osba_dirac_td_binaural_jbm(
            int16_t i;
            for ( i = 0; i < nSamplesAsked; i++ )
            {
#ifndef NONBE_1894_OSBA_SCALING
                output_f[n][i] = 0.5f * output_f[channel_offset + n][i] + 0.5f * p_sepobj[n][i];
#else
                output_f[n][i] = output_f[channel_offset + n][i] + p_sepobj[n][i];
#endif
            }
        }
    }
@@ -306,15 +292,11 @@ ivas_error ivas_osba_render_sf(
        {
            v_add( p_output[n], p_output_ism[n], p_output[n], *nSamplesRendered );
        }
#ifndef NONBE_1894_OSBA_SCALING
        v_multc( p_output[n], 0.5f, p_output[n], *nSamplesRendered );
#endif
    }

    return IVAS_ERR_OK;
}

#ifdef NONBE_1894_OSBA_SCALING
/*-------------------------------------------------------------------------*
 * ivas_osba_stereo_add_channels()
 *
@@ -360,4 +342,3 @@ void ivas_osba_stereo_add_channels(

    return;
}
#endif