Loading apps/renderer.c +19 −0 Original line number Diff line number Diff line Loading @@ -564,12 +564,27 @@ static void setupWithSingleFormatInput( positionProvider->numObjects = args.inConfig.numAudioObjects; for ( int16_t i = 0; i < positionProvider->numObjects; ++i ) { #ifdef FIX_1376_MISSING_ISM_METADATA /* Check if path to metadata file was given */ if ( isEmptyString( args.inMetadataFilePaths[i] ) ) { fprintf( stderr, "No metadata file was given for ISM input %d\n", i ); exit( -1 ); } /* It is allowed on CLI to have no metadata for an ISM input - skip opening if string contains "NULL" */ #else /* It is allowed on CLI to have no metadata for an ISM input - skip opening if string is empty or contains "NULL" */ #endif char charBuf[FILENAME_MAX]; strncpy( charBuf, args.inMetadataFilePaths[i], min( FILENAME_MAX, RENDERER_MAX_CLI_ARG_LENGTH ) - 1 ); charBuf[min( FILENAME_MAX, RENDERER_MAX_CLI_ARG_LENGTH ) - 1] = '\0'; to_upper( charBuf ); #ifdef FIX_1376_MISSING_ISM_METADATA if ( strncmp( charBuf, "NULL", 4 ) == 0 ) #else if ( isEmptyString( args.inMetadataFilePaths[i] ) || strncmp( charBuf, "NULL", 4 ) == 0 ) #endif { continue; } Loading Loading @@ -2595,7 +2610,11 @@ static CmdlnArgs defaultArgs( args.outConfig.outSetupCustom.num_lfe = 0; args.inConfig.ambisonicsBuses->audioConfig = IVAS_AUDIO_CONFIG_INVALID; #ifdef FIX_1376_MISSING_ISM_METADATA for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS + RENDERER_MAX_MASA_INPUTS; ++i ) #else for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i ) #endif { clearString( args.inMetadataFilePaths[i] ); } Loading lib_com/options.h +1 −1 Original line number Diff line number Diff line Loading @@ -165,9 +165,9 @@ #define TMP_FIX_1119_SPLIT_RENDERING_VOIP /* FhG: Add error check for unsupported config: split rendering with VoIP mode */ #define FIX_1348_OVERFLOW /* FhG: fix BASOP overflow in hq_lr_dec(), brings floating-point code inline with FX */ #define FIX_1369_HQ_LR_OVERFLOW /* FhG: fix BASOP overflow in hq_lr_enc(), brings floating-point code inline with FX */ #define FIX_1376_MISSING_ISM_METADATA /* FhG: IVAS_rend: throw error if there exists an ISM input without a corresponding metadata file path */ #define FIX_1330_JBM_MEMORY /* VA: issue 1330: memory savings in the JBM decoder */ /* #################### End BE switches ################################## */ /* #################### Start NON-BE switches ############################ */ Loading tests/renderer/utils.py +7 −0 Original line number Diff line number Diff line Loading @@ -273,6 +273,13 @@ def run_renderer( if in_meta_files is None and in_fmt in format_to_metadata_files: in_meta_files = format_to_metadata_files[in_fmt] # If metadata not given with ISM input, use default NULL if in_meta_files is None and isinstance(in_fmt, str) and "ism" in in_fmt.lower(): match = re.search(r"ism(\d)", in_fmt.lower()) assert match is not None num_obj = int(match[1]) in_meta_files = ["NULL"] * num_obj if out_file is None: out_file_stem = f"{in_name}_to_{out_name}{trj_name}{non_diegetic_pan}{refrot_name}{refvec_name}{refveclev_name}{config_name}{framing_name}{hrtf_file_name}{name_extension}{aeid_name}_{sr}.wav" out_file = str(output_path_base.joinpath(out_file_stem)) Loading Loading
apps/renderer.c +19 −0 Original line number Diff line number Diff line Loading @@ -564,12 +564,27 @@ static void setupWithSingleFormatInput( positionProvider->numObjects = args.inConfig.numAudioObjects; for ( int16_t i = 0; i < positionProvider->numObjects; ++i ) { #ifdef FIX_1376_MISSING_ISM_METADATA /* Check if path to metadata file was given */ if ( isEmptyString( args.inMetadataFilePaths[i] ) ) { fprintf( stderr, "No metadata file was given for ISM input %d\n", i ); exit( -1 ); } /* It is allowed on CLI to have no metadata for an ISM input - skip opening if string contains "NULL" */ #else /* It is allowed on CLI to have no metadata for an ISM input - skip opening if string is empty or contains "NULL" */ #endif char charBuf[FILENAME_MAX]; strncpy( charBuf, args.inMetadataFilePaths[i], min( FILENAME_MAX, RENDERER_MAX_CLI_ARG_LENGTH ) - 1 ); charBuf[min( FILENAME_MAX, RENDERER_MAX_CLI_ARG_LENGTH ) - 1] = '\0'; to_upper( charBuf ); #ifdef FIX_1376_MISSING_ISM_METADATA if ( strncmp( charBuf, "NULL", 4 ) == 0 ) #else if ( isEmptyString( args.inMetadataFilePaths[i] ) || strncmp( charBuf, "NULL", 4 ) == 0 ) #endif { continue; } Loading Loading @@ -2595,7 +2610,11 @@ static CmdlnArgs defaultArgs( args.outConfig.outSetupCustom.num_lfe = 0; args.inConfig.ambisonicsBuses->audioConfig = IVAS_AUDIO_CONFIG_INVALID; #ifdef FIX_1376_MISSING_ISM_METADATA for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS + RENDERER_MAX_MASA_INPUTS; ++i ) #else for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i ) #endif { clearString( args.inMetadataFilePaths[i] ); } Loading
lib_com/options.h +1 −1 Original line number Diff line number Diff line Loading @@ -165,9 +165,9 @@ #define TMP_FIX_1119_SPLIT_RENDERING_VOIP /* FhG: Add error check for unsupported config: split rendering with VoIP mode */ #define FIX_1348_OVERFLOW /* FhG: fix BASOP overflow in hq_lr_dec(), brings floating-point code inline with FX */ #define FIX_1369_HQ_LR_OVERFLOW /* FhG: fix BASOP overflow in hq_lr_enc(), brings floating-point code inline with FX */ #define FIX_1376_MISSING_ISM_METADATA /* FhG: IVAS_rend: throw error if there exists an ISM input without a corresponding metadata file path */ #define FIX_1330_JBM_MEMORY /* VA: issue 1330: memory savings in the JBM decoder */ /* #################### End BE switches ################################## */ /* #################### Start NON-BE switches ############################ */ Loading
tests/renderer/utils.py +7 −0 Original line number Diff line number Diff line Loading @@ -273,6 +273,13 @@ def run_renderer( if in_meta_files is None and in_fmt in format_to_metadata_files: in_meta_files = format_to_metadata_files[in_fmt] # If metadata not given with ISM input, use default NULL if in_meta_files is None and isinstance(in_fmt, str) and "ism" in in_fmt.lower(): match = re.search(r"ism(\d)", in_fmt.lower()) assert match is not None num_obj = int(match[1]) in_meta_files = ["NULL"] * num_obj if out_file is None: out_file_stem = f"{in_name}_to_{out_name}{trj_name}{non_diegetic_pan}{refrot_name}{refvec_name}{refveclev_name}{config_name}{framing_name}{hrtf_file_name}{name_extension}{aeid_name}_{sr}.wav" out_file = str(output_path_base.joinpath(out_file_stem)) Loading