Loading lib_dec/ivas_spar_md_dec.c +1 −22 Original line number Diff line number Diff line Loading @@ -2873,9 +2873,6 @@ void ivas_spar_to_dirac( float dvx[IVAS_MAX_NUM_BANDS], dvy[IVAS_MAX_NUM_BANDS], dvz[IVAS_MAX_NUM_BANDS]; float radius; float en_ratio, res_pow; #ifdef ENABLE_DITHER int16_t *seed_ptr; #endif int16_t num_slots_in_subfr; int16_t tmp_write_idx_param_band; int16_t tmp_write_idx_band; Loading @@ -2898,9 +2895,6 @@ void ivas_spar_to_dirac( if ( hDirAC != NULL && ivas_get_hodirac_flag( st_ivas->hDecoderConfig->ivas_total_brate, st_ivas->sba_analysis_order ) == 0 ) { band_grouping = hDirAC->band_grouping; #ifdef ENABLE_DITHER seed_ptr = &hDirAC->dithering_seed; #endif num_slots_in_subfr = st_ivas->hDirAC->hConfig->dec_param_estim ? CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES : 1; for ( band = start_band; band < end_band; band++ ) Loading Loading @@ -2975,17 +2969,10 @@ void ivas_spar_to_dirac( for ( band = start_band; band < end_band; band++ ) { #ifdef ENABLE_DITHER int16_t diff_idx, azi_dith, ele_dith; #else int16_t azi_dith, ele_dith; #endif tmp_write_idx_param_band = hDirAC->spar_to_dirac_write_idx; en_ratio = 1.0f - diffuseness[band]; #ifdef ENABLE_DITHER diff_idx = #endif masa_sq( 1.0f - en_ratio, diffuseness_thresholds, DIRAC_DIFFUSE_LEVELS ); qmf_band_start = band_grouping[band]; Loading @@ -3000,16 +2987,8 @@ void ivas_spar_to_dirac( for ( b = qmf_band_start; b < qmf_band_end; b++ ) { #ifdef ENABLE_DITHER azi_dith = (int16_t) ( azi[band] + rand_triangular_signed( seed_ptr ) * dirac_dithering_azi_scale[diff_idx] + 0.5f ); ele_dith = (int16_t) ( ele[band] + rand_triangular_signed( seed_ptr ) * dirac_dithering_ele_scale[diff_idx] + 0.5f ); /* limit the elevation to [-90, 90] */ ele_dith = min( 90, ele_dith ); ele_dith = max( -90, ele_dith ); #else azi_dith = azi[band]; ele_dith = ele[band]; #endif hDirAC->energy_ratio1[block][b] = en_ratio; tmp_write_idx_band = tmp_write_idx_param_band; Loading lib_enc/lib_enc.c +0 −12 Original line number Diff line number Diff line Loading @@ -110,13 +110,7 @@ ivas_error IVAS_ENC_Open( * Allocate and initialize IVAS application encoder handle *-----------------------------------------------------------------*/ #ifdef BITSTREAM_INDICES_MEMORY #define WMC_TOOL_SKIP if ( ( *phIvasEnc = (IVAS_ENC_HANDLE) malloc( sizeof( struct IVAS_ENC ) ) ) == NULL ) #undef WMC_TOOL_SKIP #else if ( ( *phIvasEnc = (IVAS_ENC_HANDLE) malloc( sizeof( struct IVAS_ENC ) ) ) == NULL ) #endif { return IVAS_ERR_FAILED_ALLOC; } Loading Loading @@ -205,13 +199,7 @@ void IVAS_ENC_Close( ( *phIvasEnc )->st_ivas = NULL; #ifdef BITSTREAM_INDICES_MEMORY #define WMC_TOOL_SKIP free( *phIvasEnc ); #undef WMC_TOOL_SKIP #else free( *phIvasEnc ); #endif *phIvasEnc = NULL; phIvasEnc = NULL; Loading tests/codec_be_on_mr_selection/__init__.py +1 −1 Original line number Diff line number Diff line Loading @@ -94,7 +94,7 @@ def apply_error_pattern_on_bitstream( if in_bitstream == out_bitstream: in_bitstream = Path(tmpdir).joinpath(in_bitstream.name) cmd = ["eid-xor", "-vbr", "-fer", in_bitstream, error_pattern, out_bitstream] cmd = ["eid-xor", "-vbr", "-fer", str(in_bitstream), str(error_pattern), str(out_bitstream)] subprocess.run(cmd) Loading Loading
lib_dec/ivas_spar_md_dec.c +1 −22 Original line number Diff line number Diff line Loading @@ -2873,9 +2873,6 @@ void ivas_spar_to_dirac( float dvx[IVAS_MAX_NUM_BANDS], dvy[IVAS_MAX_NUM_BANDS], dvz[IVAS_MAX_NUM_BANDS]; float radius; float en_ratio, res_pow; #ifdef ENABLE_DITHER int16_t *seed_ptr; #endif int16_t num_slots_in_subfr; int16_t tmp_write_idx_param_band; int16_t tmp_write_idx_band; Loading @@ -2898,9 +2895,6 @@ void ivas_spar_to_dirac( if ( hDirAC != NULL && ivas_get_hodirac_flag( st_ivas->hDecoderConfig->ivas_total_brate, st_ivas->sba_analysis_order ) == 0 ) { band_grouping = hDirAC->band_grouping; #ifdef ENABLE_DITHER seed_ptr = &hDirAC->dithering_seed; #endif num_slots_in_subfr = st_ivas->hDirAC->hConfig->dec_param_estim ? CLDFB_NO_COL_MAX / MAX_PARAM_SPATIAL_SUBFRAMES : 1; for ( band = start_band; band < end_band; band++ ) Loading Loading @@ -2975,17 +2969,10 @@ void ivas_spar_to_dirac( for ( band = start_band; band < end_band; band++ ) { #ifdef ENABLE_DITHER int16_t diff_idx, azi_dith, ele_dith; #else int16_t azi_dith, ele_dith; #endif tmp_write_idx_param_band = hDirAC->spar_to_dirac_write_idx; en_ratio = 1.0f - diffuseness[band]; #ifdef ENABLE_DITHER diff_idx = #endif masa_sq( 1.0f - en_ratio, diffuseness_thresholds, DIRAC_DIFFUSE_LEVELS ); qmf_band_start = band_grouping[band]; Loading @@ -3000,16 +2987,8 @@ void ivas_spar_to_dirac( for ( b = qmf_band_start; b < qmf_band_end; b++ ) { #ifdef ENABLE_DITHER azi_dith = (int16_t) ( azi[band] + rand_triangular_signed( seed_ptr ) * dirac_dithering_azi_scale[diff_idx] + 0.5f ); ele_dith = (int16_t) ( ele[band] + rand_triangular_signed( seed_ptr ) * dirac_dithering_ele_scale[diff_idx] + 0.5f ); /* limit the elevation to [-90, 90] */ ele_dith = min( 90, ele_dith ); ele_dith = max( -90, ele_dith ); #else azi_dith = azi[band]; ele_dith = ele[band]; #endif hDirAC->energy_ratio1[block][b] = en_ratio; tmp_write_idx_band = tmp_write_idx_param_band; Loading
lib_enc/lib_enc.c +0 −12 Original line number Diff line number Diff line Loading @@ -110,13 +110,7 @@ ivas_error IVAS_ENC_Open( * Allocate and initialize IVAS application encoder handle *-----------------------------------------------------------------*/ #ifdef BITSTREAM_INDICES_MEMORY #define WMC_TOOL_SKIP if ( ( *phIvasEnc = (IVAS_ENC_HANDLE) malloc( sizeof( struct IVAS_ENC ) ) ) == NULL ) #undef WMC_TOOL_SKIP #else if ( ( *phIvasEnc = (IVAS_ENC_HANDLE) malloc( sizeof( struct IVAS_ENC ) ) ) == NULL ) #endif { return IVAS_ERR_FAILED_ALLOC; } Loading Loading @@ -205,13 +199,7 @@ void IVAS_ENC_Close( ( *phIvasEnc )->st_ivas = NULL; #ifdef BITSTREAM_INDICES_MEMORY #define WMC_TOOL_SKIP free( *phIvasEnc ); #undef WMC_TOOL_SKIP #else free( *phIvasEnc ); #endif *phIvasEnc = NULL; phIvasEnc = NULL; Loading
tests/codec_be_on_mr_selection/__init__.py +1 −1 Original line number Diff line number Diff line Loading @@ -94,7 +94,7 @@ def apply_error_pattern_on_bitstream( if in_bitstream == out_bitstream: in_bitstream = Path(tmpdir).joinpath(in_bitstream.name) cmd = ["eid-xor", "-vbr", "-fer", in_bitstream, error_pattern, out_bitstream] cmd = ["eid-xor", "-vbr", "-fer", str(in_bitstream), str(error_pattern), str(out_bitstream)] subprocess.run(cmd) Loading