Commit 47957122 authored by Archit Tamarapu's avatar Archit Tamarapu
Browse files

align with latest main and revert unneeded changes

parent cffb88de
Loading
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -2,8 +2,8 @@ cmake_minimum_required(VERSION 3.10)

project(generate_crend_ivas_tables)

set(CMAKE_OSX_ARCHITECTURES "x86_64")
set(CMAKE_GENERATOR_PLATFORM x64)
#set(CMAKE_OSX_ARCHITECTURES "x86_64")
#set(CMAKE_GENERATOR_PLATFORM x64)
set(CMAKE_BUILD_TYPE "Debug")
set(IVAS_TRUNK_PATH "${PROJECT_SOURCE_DIR}/../..")
set(IVAS_TRUNK_UTIL_PATH ${IVAS_TRUNK_PATH}/lib_util)
@@ -15,8 +15,8 @@ set(IVAS_TRUNK_COM_PATH ${IVAS_TRUNK_PATH}/lib_com)
set(IVAS_TRUNK_ISAR_PATH ${IVAS_TRUNK_PATH}/lib_isar)
set(IVAS_TRUNK_LC3_PATH ${IVAS_TRUNK_PATH}/lib_lc3plus)
set(IVAS_TRUNK_DEBUG_PATH ${IVAS_TRUNK_PATH}/lib_debug)
set(Matlab_ROOT_DIR "/Applications/MATLAB_R2020b.app")
find_package(Matlab REQUIRED COMPONENTS MAT_LIBRARY MX_LIBRARY)
#set(Matlab_ROOT_DIR "/Applications/MATLAB_R2020b.app")
#find_package(Matlab REQUIRED COMPONENTS MAT_LIBRARY MX_LIBRARY)

option(USE_MATLAB_ENG "Use matlab engine" OFF) # allows to use sofa file as input to the exe, but on windows requires to register matlab as a com server type in matlab "comserver('register')""
find_package(Matlab REQUIRED)
+1 −1
Original line number Diff line number Diff line
@@ -1660,7 +1660,7 @@ int generate_crend_ivas_tables_from_sofa( const char *file_path, ConfigReader *c
        }
        hrtf_data.latency_s += 0.000000001f;

        if ( ( sofa_N_48k > 40000 /* hack for BRIR with delta */) || ( hrtf_data.num_iterations[0][0] > 2 ) || ( hrtf_data.num_iterations_diffuse[0] > 0 ) )
        if ( ( hrtf_data.num_iterations[0][0] > 2 ) || ( hrtf_data.num_iterations_diffuse[0] > 0 ) )
        {
            strcpy( &lscfg.name[len_ls_cfg_name], "_BRIR" );
        }
+10 −10
Original line number Diff line number Diff line
@@ -52,11 +52,11 @@ addpath('./fastconv/');
addpath(genpath('../td_object_renderer/modeling_tool/'));

%% Set arguments
generateCustomBinaryFile = true;
generateCustomBinaryFile = false;
normalize = true; % put a true to normalize input HRTF file. Diffuse field spectrum will be equal to one at 1 khz. Shall not be used with BRIR
makeBE = true; % put at true to generate BE rom table and at false to support more type of sofa file
performDiffuseFieldEq = true; % at true perform diffuse field equalization during param bin taps computation. Should not by used when HRIR are alredy diffuse field equalized
writeRomFileOutput = true; %% generation of rom files if true
writeRomFileOutput = true & ~generateCustomBinaryFile; %% generation of rom files if true
writeBinaryOutput = true; %% generation of binary files if true. Always true for TD renderer
writeEachRendererBinaryOutput = false; %% generation of binary split files each containing binary data for individual renderer 
%% Set ivas root path
@@ -74,9 +74,9 @@ if generateCustomBinaryFile
    % brir_file_name = 'bbcrdlr_all_speakers.sofa'; 
    % brirOptimCfgFile = 'brir_low_complexity_optim.cfg';

    output_bin_name = 'ivas_binaural_dirac_deltas';
    hrir_file_name = 'HRIR_128_dirac_deltas.sofa';
    brir_file_name = 'BRIR_dirac_deltas.sofa';    
    output_bin_name = 'ivas_binaural_custom_no_optim';
    hrir_file_name = 'HRIR_128_Meth5_IRC_51_Q10_symL_Itrp1_48000.sofa'; % fail for TD renderer
    brir_file_name = 'BRIR_Auditorium_S1_R1_CICP19.sofa';    
    brirOptimCfgFile = 'brir_no_optim.cfg';
    
    %    hrir_file_name = 'ari-dtf_nh2.sofa'; % fail for TD renderer
@@ -88,9 +88,9 @@ if generateCustomBinaryFile
   % output_bin_name = 'ivas_binaural_custom_no_optim';
    %brir_file_name = 'IIS_BRIR_officialMPEG_Combined.sofa'    
else 
    hrir_file_name = 'HRIR_128_dirac_deltas.sofa';
    output_bin_name = 'ivas_binaural_dirac_deltas';
    brir_file_name = 'BRIR_dirac_deltas.sofa';
    hrir_file_name = 'HRIR_128_Meth5_IRC_53_Q10_symL_Itrp1_48000.sofa';
    output_bin_name = 'ivas_binaural';
    brir_file_name = 'IIS_BRIR_officialMPEG_Combined.sofa';
end
hrir_path = fullfile ('.','HRIRs_sofa');
brir_path = fullfile ('.','BRIRs_sofa');
@@ -115,7 +115,7 @@ dataSpec.dataBase = 'IVAS';
if generateCustomBinaryFile
    dataSpec.subjId = 'custom';
else
    dataSpec.subjId = 'custom';
    dataSpec.subjId = 'default';
end
% specify HR filter directory
dataSpec.hrfInDir = hrir_file;
@@ -151,7 +151,7 @@ if writeBinaryOutput == true
                ];
end

if generateCustomBinaryFile% && exist('brirOptimCfgFile', 'var') && isempty(brirOptimCfgFile)==false
if generateCustomBinaryFile && exist('brirOptimCfgFile', 'var') && isempty(brirOptimCfgFile)==false
    command = [command ...
                    ' -brir_optim_config_path ' ...
                    ' ' brirOptimCfgFile ' ' ...
+10042 −10042

File changed.

Preview size limit exceeded, changes collapsed.

+46616 −13616

File changed.

Preview size limit exceeded, changes collapsed.

Loading