Loading lib_rend/ivas_rom_TdBinauralRenderer.c +1 −1 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ * TD Binaural rendering related ROM tables *------------------------------------------------------------------------*/ /* TD renderer default HRIR model */ const float defaultHRIR_rom_latency_s = 0.000020834f; const uint32_t defaultHRIR_rom_latency_s = 0x37aec500; #ifdef FIX_989_TD_REND_ROM const int16_t defaultHRIR_rom_model_configuration[6] = { 1, /* UseItdModel */ scripts/binauralRenderer_interface/generate_ivas_binauralizer_tables_from_sofa.m +5 −4 Original line number Diff line number Diff line Loading @@ -92,13 +92,14 @@ end %% generate td binauralizer rom or binary values dataSpec.dataBase = 'IVAS'; dataSpec.subjId = 'custom'; % specify HR filter directory dataSpec.hrfInDir = hrir_file; dataSpec.hrfOutDir = binary_path; dataSpec.genRomFile = true; dataSpec.fx = true; dataSpec.genRomFile = writeRomFileOutput; dataSpec.fx = false; dataSpec.be = false; dataSpec.romOutDir = rom_path; Mod_Hrf_Itd_Main(dataSpec); Loading @@ -108,8 +109,8 @@ dataSpec.subjId = 'custom'; % specify HR filter directory dataSpec.hrfInDir = hrir_file; dataSpec.hrfOutDir = binary_path; dataSpec.genRomFile = writeRomFileOutput; dataSpec.fx = false; dataSpec.genRomFile = true; dataSpec.fx = true; dataSpec.be = false; dataSpec.romOutDir = rom_path; Mod_Hrf_Itd_Main(dataSpec); Loading scripts/td_object_renderer/modeling_tool/Gen_Hrf_IVAS_Binary.m +9 −8 Original line number Diff line number Diff line Loading @@ -183,9 +183,15 @@ if dataSpec.genRomFile fileID_c = fopen(c_file_name,'at'); if dataSpec.be [~, integerLatency, QLatency] = toInt32(single(mod.dat.hrf.hrf_latency)); else [mod.dat.hrf.hrf_latency, integerLatency, QLatency, diff] = toInt32(mod.dat.hrf.hrf_latency); end if dataSpec.fx c_file_content = string(join({ ['const float defaultHRIR_rom_latency_s = 0x' num2hex(single(mod.dat.hrf.hrf_latency)) ';'] ['const uint32_t defaultHRIR_rom_latency_s = 0x' num2hex(single(mod.dat.hrf.hrf_latency)) ';'] '' }, newline)); else Loading Loading @@ -381,14 +387,9 @@ for fs = [48000 32000 16000] % Format for file: % 0 = BSpline model fwrite(fileID, useModel, 'short'); if dataSpec.be [~, integer, Q] = toInt32(single(mod.dat.hrf.hrf_latency)); else [mod.dat.hrf.hrf_latency, integer, Q, diff] = toInt32(mod.dat.hrf.hrf_latency); end if dataSpec.fx fwrite(fileID, Q, "int16"); fwrite(fileID, integer, "int32"); fwrite(fileID, QLatency, "int16"); fwrite(fileID, integerLatency, "int32"); else fwrite(fileID, single(mod.dat.hrf.hrf_latency), 'float'); end Loading Loading
lib_rend/ivas_rom_TdBinauralRenderer.c +1 −1 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ * TD Binaural rendering related ROM tables *------------------------------------------------------------------------*/ /* TD renderer default HRIR model */ const float defaultHRIR_rom_latency_s = 0.000020834f; const uint32_t defaultHRIR_rom_latency_s = 0x37aec500; #ifdef FIX_989_TD_REND_ROM const int16_t defaultHRIR_rom_model_configuration[6] = { 1, /* UseItdModel */
scripts/binauralRenderer_interface/generate_ivas_binauralizer_tables_from_sofa.m +5 −4 Original line number Diff line number Diff line Loading @@ -92,13 +92,14 @@ end %% generate td binauralizer rom or binary values dataSpec.dataBase = 'IVAS'; dataSpec.subjId = 'custom'; % specify HR filter directory dataSpec.hrfInDir = hrir_file; dataSpec.hrfOutDir = binary_path; dataSpec.genRomFile = true; dataSpec.fx = true; dataSpec.genRomFile = writeRomFileOutput; dataSpec.fx = false; dataSpec.be = false; dataSpec.romOutDir = rom_path; Mod_Hrf_Itd_Main(dataSpec); Loading @@ -108,8 +109,8 @@ dataSpec.subjId = 'custom'; % specify HR filter directory dataSpec.hrfInDir = hrir_file; dataSpec.hrfOutDir = binary_path; dataSpec.genRomFile = writeRomFileOutput; dataSpec.fx = false; dataSpec.genRomFile = true; dataSpec.fx = true; dataSpec.be = false; dataSpec.romOutDir = rom_path; Mod_Hrf_Itd_Main(dataSpec); Loading
scripts/td_object_renderer/modeling_tool/Gen_Hrf_IVAS_Binary.m +9 −8 Original line number Diff line number Diff line Loading @@ -183,9 +183,15 @@ if dataSpec.genRomFile fileID_c = fopen(c_file_name,'at'); if dataSpec.be [~, integerLatency, QLatency] = toInt32(single(mod.dat.hrf.hrf_latency)); else [mod.dat.hrf.hrf_latency, integerLatency, QLatency, diff] = toInt32(mod.dat.hrf.hrf_latency); end if dataSpec.fx c_file_content = string(join({ ['const float defaultHRIR_rom_latency_s = 0x' num2hex(single(mod.dat.hrf.hrf_latency)) ';'] ['const uint32_t defaultHRIR_rom_latency_s = 0x' num2hex(single(mod.dat.hrf.hrf_latency)) ';'] '' }, newline)); else Loading Loading @@ -381,14 +387,9 @@ for fs = [48000 32000 16000] % Format for file: % 0 = BSpline model fwrite(fileID, useModel, 'short'); if dataSpec.be [~, integer, Q] = toInt32(single(mod.dat.hrf.hrf_latency)); else [mod.dat.hrf.hrf_latency, integer, Q, diff] = toInt32(mod.dat.hrf.hrf_latency); end if dataSpec.fx fwrite(fileID, Q, "int16"); fwrite(fileID, integer, "int32"); fwrite(fileID, QLatency, "int16"); fwrite(fileID, integerLatency, "int32"); else fwrite(fileID, single(mod.dat.hrf.hrf_latency), 'float'); end Loading