Skip to content
...@@ -795,7 +795,7 @@ static void ivas_SplitRenderer_code_md_base2( ...@@ -795,7 +795,7 @@ static void ivas_SplitRenderer_code_md_base2(
const int16_t bands_pitch, const int16_t bands_pitch,
const int16_t pred_real_bands_roll, const int16_t pred_real_bands_roll,
const int16_t pred_imag_bands_roll, const int16_t pred_imag_bands_roll,
ivas_split_rend_bits_t *pBits ) IVAS_SPLIT_REND_BITS_HANDLE pBits )
{ {
int16_t pos_idx, b, ch1, ch2, sf_idx; int16_t pos_idx, b, ch1, ch2, sf_idx;
int16_t min_pred_idx, min_gd_idx, min_p_gd_idx, pred_code_len, gd_code_len, p_gd_code_len, num_poses; int16_t min_pred_idx, min_gd_idx, min_p_gd_idx, pred_code_len, gd_code_len, p_gd_code_len, num_poses;
...@@ -941,7 +941,7 @@ static void ivas_SplitRenderer_code_md_huff( ...@@ -941,7 +941,7 @@ static void ivas_SplitRenderer_code_md_huff(
const int16_t bands_pitch, const int16_t bands_pitch,
const int16_t pred_real_bands_roll, const int16_t pred_real_bands_roll,
const int16_t pred_imag_bands_roll, const int16_t pred_imag_bands_roll,
ivas_split_rend_bits_t *pBits ) IVAS_SPLIT_REND_BITS_HANDLE pBits )
{ {
int16_t pos_idx, b, ch1, ch2, sf_idx, num_poses; int16_t pos_idx, b, ch1, ch2, sf_idx, num_poses;
int16_t sym_adj_idx[BINAURAL_CHANNELS][BINAURAL_CHANNELS]; int16_t sym_adj_idx[BINAURAL_CHANNELS][BINAURAL_CHANNELS];
...@@ -1080,7 +1080,7 @@ static void ivas_SplitRenderer_quant_code( ...@@ -1080,7 +1080,7 @@ static void ivas_SplitRenderer_quant_code(
const BIN_HR_SPLIT_PRE_REND_HANDLE hBinHrSplitPreRend, const BIN_HR_SPLIT_PRE_REND_HANDLE hBinHrSplitPreRend,
const IVAS_QUATERNION headPosition, const IVAS_QUATERNION headPosition,
MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData, MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData,
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int16_t low_res_pre_rend_rot, const int16_t low_res_pre_rend_rot,
const int32_t target_md_bits ) const int32_t target_md_bits )
{ {
...@@ -1405,7 +1405,7 @@ void ivas_rend_CldfbSplitPreRendProcess( ...@@ -1405,7 +1405,7 @@ void ivas_rend_CldfbSplitPreRendProcess(
MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData, MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData,
float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int32_t target_md_bits, const int32_t target_md_bits,
const int16_t low_res_pre_rend_rot ) const int16_t low_res_pre_rend_rot )
{ {
...@@ -2046,7 +2046,7 @@ void ivas_split_renderer_close( ...@@ -2046,7 +2046,7 @@ void ivas_split_renderer_close(
static ivas_error splitRendLc3plusEncodeAndWrite( static ivas_error splitRendLc3plusEncodeAndWrite(
SPLIT_REND_WRAPPER *hSplitBin, SPLIT_REND_WRAPPER *hSplitBin,
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int32_t SplitRendBitRate, const int32_t SplitRendBitRate,
float *in[] ) float *in[] )
{ {
...@@ -2099,7 +2099,7 @@ static ivas_error ivas_renderMultiTDBinToSplitBinaural( ...@@ -2099,7 +2099,7 @@ static ivas_error ivas_renderMultiTDBinToSplitBinaural(
const IVAS_QUATERNION headPosition, const IVAS_QUATERNION headPosition,
const int32_t SplitRendBitRate, const int32_t SplitRendBitRate,
const int16_t codec_frame_size_ms, const int16_t codec_frame_size_ms,
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int16_t max_bands, const int16_t max_bands,
float *in[], float *in[],
const int16_t low_res_pre_rend_rot, const int16_t low_res_pre_rend_rot,
...@@ -2322,7 +2322,7 @@ ivas_error ivas_renderMultiBinToSplitBinaural( ...@@ -2322,7 +2322,7 @@ ivas_error ivas_renderMultiBinToSplitBinaural(
const int32_t SplitRendBitRate, const int32_t SplitRendBitRate,
IVAS_SPLIT_REND_CODEC splitCodec, IVAS_SPLIT_REND_CODEC splitCodec,
int16_t codec_frame_size_ms, int16_t codec_frame_size_ms,
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float Cldfb_In_BinReal[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float Cldfb_In_BinImag[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
const int16_t max_bands, const int16_t max_bands,
......
...@@ -92,7 +92,7 @@ void ivas_mat_mult_2by2_complex( ...@@ -92,7 +92,7 @@ void ivas_mat_mult_2by2_complex(
*------------------------------------------------------------------------*/ *------------------------------------------------------------------------*/
void ivas_split_rend_bitstream_init( void ivas_split_rend_bitstream_init(
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int32_t buf_len_bytes, const int32_t buf_len_bytes,
uint8_t *pbuf ) uint8_t *pbuf )
{ {
...@@ -373,7 +373,7 @@ void ivas_SplitRenderer_getdiagdiff( ...@@ -373,7 +373,7 @@ void ivas_SplitRenderer_getdiagdiff(
*------------------------------------------------------------------------*/ *------------------------------------------------------------------------*/
int32_t ivas_split_rend_bitstream_read_int32( int32_t ivas_split_rend_bitstream_read_int32(
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int32_t bits ) const int32_t bits )
{ {
int32_t val, k, bit_val; int32_t val, k, bit_val;
...@@ -403,7 +403,7 @@ int32_t ivas_split_rend_bitstream_read_int32( ...@@ -403,7 +403,7 @@ int32_t ivas_split_rend_bitstream_read_int32(
*------------------------------------------------------------------------*/ *------------------------------------------------------------------------*/
void ivas_split_rend_bitstream_write_int32( void ivas_split_rend_bitstream_write_int32(
ivas_split_rend_bits_t *pBits, IVAS_SPLIT_REND_BITS_HANDLE pBits,
const int32_t val, const int32_t val,
const int32_t bits ) const int32_t bits )
{ {
......
...@@ -668,6 +668,7 @@ typedef struct ivas_external_orientation_struct ...@@ -668,6 +668,7 @@ typedef struct ivas_external_orientation_struct
int16_t numFramesToTargetOrientation[MAX_PARAM_SPATIAL_SUBFRAMES]; /* Number of frames until target orientation is reached */ int16_t numFramesToTargetOrientation[MAX_PARAM_SPATIAL_SUBFRAMES]; /* Number of frames until target orientation is reached */
IVAS_QUATERNION Quaternions[MAX_PARAM_SPATIAL_SUBFRAMES]; /* External orientation in quaternions */ IVAS_QUATERNION Quaternions[MAX_PARAM_SPATIAL_SUBFRAMES]; /* External orientation in quaternions */
int16_t num_subframes; int16_t num_subframes;
} EXTERNAL_ORIENTATION_DATA, *EXTERNAL_ORIENTATION_HANDLE; } EXTERNAL_ORIENTATION_DATA, *EXTERNAL_ORIENTATION_HANDLE;
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
...@@ -706,6 +707,7 @@ typedef struct ivas_combined_orientation_struct ...@@ -706,6 +707,7 @@ typedef struct ivas_combined_orientation_struct
int8_t isExtOrientationFrozen; int8_t isExtOrientationFrozen;
int8_t isHeadRotationFrozen; int8_t isHeadRotationFrozen;
int16_t num_subframes; int16_t num_subframes;
} COMBINED_ORIENTATION_DATA, *COMBINED_ORIENTATION_HANDLE; } COMBINED_ORIENTATION_DATA, *COMBINED_ORIENTATION_HANDLE;
...@@ -829,8 +831,8 @@ typedef struct ...@@ -829,8 +831,8 @@ typedef struct
float soundspeed; float soundspeed;
float air_coeff; float air_coeff;
shoebox_config_t cal; shoebox_config_t cal;
} shoebox_obj_t;
} shoebox_obj_t;
typedef struct shoebox_data_t typedef struct shoebox_data_t
{ {
...@@ -839,7 +841,6 @@ typedef struct shoebox_data_t ...@@ -839,7 +841,6 @@ typedef struct shoebox_data_t
} shoebox_data_t; } shoebox_data_t;
typedef struct typedef struct
{ {
uint16_t n_sources; uint16_t n_sources;
...@@ -851,6 +852,7 @@ typedef struct ...@@ -851,6 +852,7 @@ typedef struct
} shoebox_output_t; } shoebox_output_t;
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
* Reflections structure * Reflections structure
*----------------------------------------------------------------------------------*/ *----------------------------------------------------------------------------------*/
...@@ -1072,8 +1074,8 @@ typedef struct TDREND_SRC_REND_s ...@@ -1072,8 +1074,8 @@ typedef struct TDREND_SRC_REND_s
float SrcGainMax_p[SPAT_BIN_MAX_INPUT_CHANNELS]; float SrcGainMax_p[SPAT_BIN_MAX_INPUT_CHANNELS];
float DirGain_p[SPAT_BIN_MAX_INPUT_CHANNELS]; float DirGain_p[SPAT_BIN_MAX_INPUT_CHANNELS];
float DistGain_p[SPAT_BIN_MAX_INPUT_CHANNELS]; float DistGain_p[SPAT_BIN_MAX_INPUT_CHANNELS];
} TDREND_SRC_REND_t;
} TDREND_SRC_REND_t;
/* Source spatial parameters */ /* Source spatial parameters */
typedef struct typedef struct
...@@ -1106,6 +1108,7 @@ typedef struct ...@@ -1106,6 +1108,7 @@ typedef struct
float mem_hrf_right[SFX_SPAT_BIN_MAX_FILTER_LENGTH - 1]; float mem_hrf_right[SFX_SPAT_BIN_MAX_FILTER_LENGTH - 1];
float Gain; float Gain;
float prevGain; float prevGain;
} TDREND_SRC_t; } TDREND_SRC_t;
/* Top level TD binaural renderer handle */ /* Top level TD binaural renderer handle */
...@@ -1224,7 +1227,7 @@ typedef struct ivas_binaural_rendering_struct ...@@ -1224,7 +1227,7 @@ typedef struct ivas_binaural_rendering_struct
#endif #endif
/*------------------------------------------------------------------------------------------* /*------------------------------------------------------------------------------------------*
* HRTF structures - htrfs from binary files * HRTF structures - hrtfs from binary files
*------------------------------------------------------------------------------------------*/ *------------------------------------------------------------------------------------------*/
typedef struct ivas_hrtfs_crend_structure typedef struct ivas_hrtfs_crend_structure
...@@ -1237,9 +1240,7 @@ typedef struct ivas_hrtfs_crend_structure ...@@ -1237,9 +1240,7 @@ typedef struct ivas_hrtfs_crend_structure
} HRTFS_CREND, *HRTFS_CREND_HANDLE; } HRTFS_CREND, *HRTFS_CREND_HANDLE;
/* Fastconv binaural data structure */ /* Fastconv binaural data structure */
typedef struct ivas_hrtfs_fastconv_struct typedef struct ivas_hrtfs_fastconv_struct
{ {
float FASTCONV_HOA3_latency_s; float FASTCONV_HOA3_latency_s;
...@@ -1279,7 +1280,6 @@ typedef struct ivas_hrtfs_fastconv_struct ...@@ -1279,7 +1280,6 @@ typedef struct ivas_hrtfs_fastconv_struct
} HRTFS_FASTCONV, *HRTFS_FASTCONV_HANDLE; } HRTFS_FASTCONV, *HRTFS_FASTCONV_HANDLE;
typedef struct ivas_hrtfs_parambin_struct typedef struct ivas_hrtfs_parambin_struct
{ {
float hrtfShCoeffsRe[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS]; float hrtfShCoeffsRe[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS];
...@@ -1512,7 +1512,6 @@ typedef struct ivas_LS_setupconversion_struct ...@@ -1512,7 +1512,6 @@ typedef struct ivas_LS_setupconversion_struct
} LSSETUP_CONVERSION_STRUCT, *LSSETUP_CONVERSION_HANDLE; } LSSETUP_CONVERSION_STRUCT, *LSSETUP_CONVERSION_HANDLE;
typedef struct ivas_LS_setupconversion_matrix typedef struct ivas_LS_setupconversion_matrix
{ {
int16_t index; int16_t index;
...@@ -1562,6 +1561,7 @@ typedef struct ...@@ -1562,6 +1561,7 @@ typedef struct
int32_t binaural_latency_ns; int32_t binaural_latency_ns;
BINAURAL_RENDERER_HANDLE hCldfbRend; BINAURAL_RENDERER_HANDLE hCldfbRend;
HRTFS_FASTCONV_HANDLE hHrtfFastConv; HRTFS_FASTCONV_HANDLE hHrtfFastConv;
} CLDFB_REND_WRAPPER; } CLDFB_REND_WRAPPER;
#endif #endif
......
This diff is collapsed.
...@@ -48,19 +48,6 @@ ...@@ -48,19 +48,6 @@
#define RENDERER_MAX_BIN_INPUTS 1 #define RENDERER_MAX_BIN_INPUTS 1
#endif #endif
#ifdef SPLIT_REND_WITH_HEAD_ROT
/*----------------------------------------------------------------------------------*
* Split rendering bitrate constants
*----------------------------------------------------------------------------------*/
#define SPLIT_REND_256k 256000
#define SPLIT_REND_320k 320000
#define SPLIT_REND_384k 384000
#define SPLIT_REND_512k 512000
#define SPLIT_REND_768k 768000
#define SPLIT_REND_MAX_BRATE SPLIT_REND_768k
#define SPLIT_REND_ADDITIONAL_BYTES_TO_READ 1
#endif
/*---------------------------------------------------------------------* /*---------------------------------------------------------------------*
* Renderer structures * Renderer structures
...@@ -275,9 +262,9 @@ ivas_error IVAS_REND_SetHeadRotation( ...@@ -275,9 +262,9 @@ ivas_error IVAS_REND_SetHeadRotation(
const IVAS_QUATERNION headRot, /* i : head orientations for next rendering call */ const IVAS_QUATERNION headRot, /* i : head orientations for next rendering call */
const IVAS_VECTOR3 Pos, /* i : listener positions for next rendering call */ const IVAS_VECTOR3 Pos, /* i : listener positions for next rendering call */
#ifdef SPLIT_REND_WITH_HEAD_ROT #ifdef SPLIT_REND_WITH_HEAD_ROT
IVAS_SPLIT_REND_ROT_AXIS rot_axis, const IVAS_SPLIT_REND_ROT_AXIS rot_axis, /* i : external control for rotation axis for split rendering*/
#endif #endif
const int16_t sf_idx const int16_t sf_idx /* i : subframe index */
); );
/* Head rotation becomes enabled by calling IVAS_REND_SetHeadRotation. Use this to disable. */ /* Head rotation becomes enabled by calling IVAS_REND_SetHeadRotation. Use this to disable. */
......
...@@ -2874,6 +2874,7 @@ ivas_error RenderConfigReader_getDirectivity( ...@@ -2874,6 +2874,7 @@ ivas_error RenderConfigReader_getDirectivity(
id[n] = last_specified_id; id[n] = last_specified_id;
} }
for ( n = 0; n < MAX_NUM_OBJECTS; n++ ) for ( n = 0; n < MAX_NUM_OBJECTS; n++ )
{ {
idExists = false; idExists = false;
......
...@@ -354,7 +354,7 @@ ivas_error split_rend_read_bits_from_file( ...@@ -354,7 +354,7 @@ ivas_error split_rend_read_bits_from_file(
{ {
return IVAS_ERR_FAILED_FILE_READ; return IVAS_ERR_FAILED_FILE_READ;
} }
for ( i = 0; i < SPLIT_REND_ADDITIONAL_BYTES_TO_READ; i++ ) for ( i = 0; i < IVAS_SPLIT_REND_ADDITIONAL_BYTES_TO_READ; i++ )
{ {
bits[num_bytes + i] = 0; bits[num_bytes + i] = 0;
} }
......
...@@ -1254,6 +1254,11 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit ...@@ -1254,6 +1254,11 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP HOA3 32 netsimoutput testv/stv3OA32c.wav_SBA_80000_32-32_HOA3_JBM5.tst ../IVAS_dec -Tracefile tracefile_dec -VOIP HOA3 32 netsimoutput testv/stv3OA32c.wav_SBA_80000_32-32_HOA3_JBM5.tst
// SBA at 13.2 kbps, 48kHz in, 48kHz out, BINAURAL out, JBM Prof 5
../IVAS_cod -sba 1 13200 48 testv/stvFOA48c.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stvFOA32c.wav_SBA_13200_48-48_BINAURAL_JBM5.tst
// Multi-channel 5_1 at 384 kbps, 48kHz in, 48kHz out, 7_1_4 out, JBM Prof 5 // Multi-channel 5_1 at 384 kbps, 48kHz in, 48kHz out, 7_1_4 out, JBM Prof 5
../IVAS_cod -mc 5_1 384000 48 testv/stv51MC48c.wav bit ../IVAS_cod -mc 5_1 384000 48 testv/stv51MC48c.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit netsimoutput tracefile_sim 2 0
......
...@@ -67,7 +67,7 @@ ivas_br_FOA = [ ...@@ -67,7 +67,7 @@ ivas_br_FOA = [
] ]
ivas_br_HOA2 = ["256000", "384000", "512000"] ivas_br_HOA2 = ["256000", "384000", "512000"]
ivas_br_HOA3 = ["256000", "384000", "512000"] ivas_br_HOA3 = ["256000", "384000", "512000"]
SID_list = [0, 1]
sample_rate_list = ["48", "32", "16"] sample_rate_list = ["48", "32", "16"]
bypass_list = [1, 2] bypass_list = [1, 2]
gain_list = [0, 1] gain_list = [0, 1]
...@@ -162,6 +162,7 @@ def test_bypass_enc( ...@@ -162,6 +162,7 @@ def test_bypass_enc(
@pytest.mark.parametrize("tag", tag_list) @pytest.mark.parametrize("tag", tag_list)
@pytest.mark.parametrize("fs", sample_rate_list) @pytest.mark.parametrize("fs", sample_rate_list)
@pytest.mark.parametrize("gain_flag", gain_list) @pytest.mark.parametrize("gain_flag", gain_list)
@pytest.mark.parametrize("SID", SID_list)
def test_sba_enc_system( def test_sba_enc_system(
dut_encoder_frontend: EncoderFrontend, dut_encoder_frontend: EncoderFrontend,
dut_decoder_frontend: DecoderFrontend, dut_decoder_frontend: DecoderFrontend,
...@@ -178,17 +179,19 @@ def test_sba_enc_system( ...@@ -178,17 +179,19 @@ def test_sba_enc_system(
tag, tag,
fs, fs,
gain_flag, gain_flag,
SID,
): ):
SID = 0
if dtx == "1" and ivas_br not in ["13200", "16400", "24400", "32000", "64000"]: if dtx == "1" and ivas_br not in ["13200", "16400", "24400", "32000", "64000"]:
# skip high bitrates for DTX until DTX issue is resolved # skip high bitrates for DTX until DTX issue is resolved
pytest.skip() pytest.skip()
if ivas_br == "sw_24k4_256k.bin" and gain_flag != 1: if SID == 1:
if ivas_br not in ["13200", "16400", "64000"] or fs == "16" or gain_flag == 1 or dtx == "0":
pytest.skip() pytest.skip()
if ivas_br == "13200" or ivas_br == "16400":
if dtx == "1" and gain_flag == 0 and fs != "16":
SID = 1
else: else:
if ivas_br in ["13200","16400"]:
pytest.skip()
if ivas_br == "sw_24k4_256k.bin" and gain_flag != 1:
pytest.skip() pytest.skip()
if gain_flag == 1 and ivas_br not in ["13200", "16400", "24400", "32000"]: if gain_flag == 1 and ivas_br not in ["13200", "16400", "24400", "32000"]:
pytest.skip() pytest.skip()
......