Skip to content
Commits on Source (14)
......@@ -82,6 +82,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -129,6 +130,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -82,6 +82,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -137,6 +138,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -72,6 +72,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -109,6 +110,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -68,6 +68,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Lib>
<OutputFile>$(OutDir)$(TargetName).lib</OutputFile>
......@@ -94,6 +95,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Lib>
<OutputFile>$(OutDir)$(TargetName).lib</OutputFile>
......
......@@ -82,6 +82,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -124,6 +125,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -82,6 +82,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -128,6 +129,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -82,6 +82,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -124,6 +125,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -67,6 +67,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Lib>
<OutputFile>$(OutDir)$(TargetName).lib</OutputFile>
......@@ -90,6 +91,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<Lib>
<OutputFile>$(OutDir)$(TargetName).lib</OutputFile>
......
......@@ -79,6 +79,7 @@
<DebugInformationFormat>OldStyle</DebugInformationFormat>
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......@@ -126,6 +127,7 @@
<DebugInformationFormat />
<CompileAs>Default</CompileAs>
<DisableSpecificWarnings>%(DisableSpecificWarnings)</DisableSpecificWarnings>
<TreatWarningAsError>false</TreatWarningAsError>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
......
......@@ -2110,7 +2110,22 @@ static ivas_error initOnFirstGoodFrame(
if ( numInitialBadFrames > 0 )
{
/* Duplicate good first frame metadata to fill the beginning of stream. */
#ifdef NONBE_FIX_1261_MASA_EXT_META_JBM
int16_t fullDelayNumSamplesLocal[3];
int32_t delayTimeScaleLocal;
float delayMs;
IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
hMasaExtOutMeta = NULL;
/* fullDelayNumSamples is zeroed so need to re-fetch delay info */
if ( ( error = IVAS_DEC_GetDelay( hIvasDec, fullDelayNumSamplesLocal, &delayTimeScaleLocal ) ) != IVAS_ERR_OK )
{
fprintf( stderr, "\nUnable to get delay of decoder: %s\n", ivas_error_to_string( error ) );
}
delayMs = (float) ( fullDelayNumSamplesLocal[0] ) / (float) ( delayTimeScaleLocal );
#else
IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta = NULL;
#endif
if ( ( error = IVAS_DEC_GetMasaMetadata( hIvasDec, &hMasaExtOutMeta, 0 ) ) != IVAS_ERR_OK )
{
......@@ -2120,7 +2135,9 @@ static ivas_error initOnFirstGoodFrame(
for ( int16_t j = 0; j < numInitialBadFrames; ++j )
{
#ifndef NONBE_FIX_1261_MASA_EXT_META_JBM
float delayMs = (float) ( pFullDelayNumSamples[0] ) / (float) ( *delayTimeScale );
#endif
if ( ( error = MasaFileWriter_writeFrame( *ppMasaWriter, hMasaExtOutMeta, &delayMs ) ) != IVAS_ERR_OK )
{
fprintf( stderr, "\nError writing MASA metadata to file: %s\n", MasaFileWriter_getFilePath( *ppMasaWriter ) );
......
......@@ -169,6 +169,10 @@
#define FIX_1320_STACK_CPE_DECODER /* VA: issue 1320: Optimize the stack memory consumption in the CPE decoder */
#define NONBE_1302_FIX_OMASA_JBM_FLUSH /* VA: issue 1302: fix OMASA JBM bitrate switching flush in binaural output */
#define FIX_1319_STACK_SBA_DECODER /* VA: issue 1319: Optimize the definition of buffer lengths in the SBA decoder */
#define NONBE_FIX_1261_MASA_EXT_META_JBM /* Nokia: issue #1261: MASA metadata EXT output delay buffer init in JBM */
#define NONBE_FIX_1143_MASA_BRSW /* Nok: Fix for issue 1143: MSAN use of uninitialized value in masa decoding to binaural with dtx bitrate switching and 5 % FER */
#define NONBE_FIX_1220_OMASA_JBM_EXT_USAN /* Nokia: fix issue 1220 OMASA EXT JBM USAN, also fix similar cases of free to avoid future problems */
/* #################### End BASOP porting switches ############################ */
/* clang-format on */
......
......@@ -1337,7 +1337,12 @@ ivas_error ivas_masa_dec_reconfigure(
ivas_total_brate = st_ivas->hDecoderConfig->ivas_total_brate;
last_ivas_total_brate = st_ivas->hDecoderConfig->last_ivas_total_brate;
#ifdef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
/* Copy state to TC buffer if granularity matches and we are not in OMASA EXT rendering mode */
if ( st_ivas->hSpatParamRendCom != NULL && st_ivas->hSpatParamRendCom->slot_size == st_ivas->hTcBuffer->n_samples_granularity && st_ivas->hDecoderConfig->output_config != IVAS_AUDIO_CONFIG_EXTERNAL )
#else
if ( st_ivas->hSpatParamRendCom != NULL && st_ivas->hSpatParamRendCom->slot_size == st_ivas->hTcBuffer->n_samples_granularity )
#endif
{
mvs2s( st_ivas->hSpatParamRendCom->subframe_nbslots, st_ivas->hTcBuffer->subframe_nbslots, MAX_JBM_SUBFRAMES_5MS );
st_ivas->hTcBuffer->nb_subframes = st_ivas->hSpatParamRendCom->nb_subframes;
......@@ -1358,6 +1363,16 @@ ivas_error ivas_masa_dec_reconfigure(
return error;
}
}
#ifdef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
else if ( st_ivas->renderer_type == RENDERER_DISABLE || st_ivas->renderer_type == RENDERER_MONO_DOWNMIX || st_ivas->renderer_type == RENDERER_OMASA_MIX_EXT )
{
/* close all unnecessary parametric decoding and rendering */
ivas_dirac_dec_close_binaural_data( st_ivas->hDiracDecBin );
ivas_dirac_rend_close( &( st_ivas->hDirACRend ) );
ivas_spat_hSpatParamRendCom_close( &( st_ivas->hSpatParamRendCom ) );
ivas_dirac_dec_close( &( st_ivas->hDirAC ) );
}
#else
else if ( st_ivas->renderer_type == RENDERER_DISABLE || st_ivas->renderer_type == RENDERER_MONO_DOWNMIX )
{
if ( st_ivas->hDirAC != NULL )
......@@ -1369,6 +1384,7 @@ ivas_error ivas_masa_dec_reconfigure(
ivas_dirac_dec_close( &( st_ivas->hDirAC ) );
}
}
#endif
/* possible reconfigure is done later */
/*-----------------------------------------------------------------*
......@@ -1408,8 +1424,14 @@ ivas_error ivas_masa_dec_reconfigure(
sts = st_ivas->hCPE[cpe_id]->hCoreCoder;
sts[0]->bit_stream = bit_stream + num_bits;
num_bits += (int16_t) ( st_ivas->hCPE[cpe_id]->element_brate / FRAMES_PER_SEC );
#ifdef NONBE_FIX_1143_MASA_BRSW
if ( ( ivas_total_brate < MASA_STEREO_MIN_BITRATE && last_ivas_total_brate >= MASA_STEREO_MIN_BITRATE ) ||
( ivas_total_brate < MASA_STEREO_MIN_BITRATE && last_ivas_total_brate == FRAME_NO_DATA ) ||
( ivas_total_brate < MASA_STEREO_MIN_BITRATE && last_ivas_total_brate == IVAS_SID_5k2 ) )
#else
if ( ( ivas_total_brate < MASA_STEREO_MIN_BITRATE && last_ivas_total_brate >= MASA_STEREO_MIN_BITRATE ) ||
( ivas_total_brate < MASA_STEREO_MIN_BITRATE && last_ivas_total_brate == FRAME_NO_DATA ) )
#endif
{
st_ivas->hCPE[cpe_id]->nchan_out = 1;
......
......@@ -851,13 +851,17 @@ static ivas_error ivas_mc_dec_reconfig(
ivas_masa_dec_close( &( st_ivas->hMasa ) );
ivas_qmetadata_close( &st_ivas->hQMetaData );
#ifndef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
if ( st_ivas->hDirAC != NULL )
{
#endif
ivas_dirac_rend_close( &( st_ivas->hDirACRend ) );
ivas_spat_hSpatParamRendCom_close( &( st_ivas->hSpatParamRendCom ) );
ivas_dirac_dec_close( &( st_ivas->hDirAC ) );
vbap_free_data( &( st_ivas->hVBAPdata ) );
#ifndef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
}
#endif
/* init LS conversion if the renderer type asks for it */
if ( st_ivas->renderer_type == RENDERER_MC && st_ivas->hLsSetUpConversion == NULL )
......@@ -937,14 +941,18 @@ static ivas_error ivas_mc_dec_reconfig(
ivas_masa_dec_close( &( st_ivas->hMasa ) );
ivas_qmetadata_close( &st_ivas->hQMetaData );
#ifndef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
if ( st_ivas->hDirAC != NULL )
{
#endif
ivas_dirac_rend_close( &( st_ivas->hDirACRend ) );
ivas_spat_hSpatParamRendCom_close( &( st_ivas->hSpatParamRendCom ) );
ivas_dirac_dec_close( &( st_ivas->hDirAC ) );
vbap_free_data( &( st_ivas->hVBAPdata ) );
#ifndef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
}
#endif
if ( last_mc_mode == MC_MODE_MCT )
{
......@@ -1144,7 +1152,11 @@ static ivas_error ivas_mc_dec_reconfig(
}
}
}
#ifdef NONBE_FIX_1220_OMASA_JBM_EXT_USAN
else if ( st_ivas->renderer_type == RENDERER_DISABLE )
#else
else if ( st_ivas->renderer_type == RENDERER_DISABLE && st_ivas->hDirAC != NULL )
#endif
{
ivas_dirac_rend_close( &( st_ivas->hDirACRend ) );
ivas_spat_hSpatParamRendCom_close( &( st_ivas->hSpatParamRendCom ) );
......
This diff is collapsed.
......@@ -30,10 +30,10 @@
*******************************************************************************************************/
#ifndef _IVAS_ROM_TDBINAURALRENDERER_
#define _IVAS_ROM_TDBINAURALRENDERER_
#include <stdint.h>
#include "options.h"
#ifdef DEBUGGING
......@@ -47,11 +47,7 @@
*------------------------------------------------------------------------*/
/* TD renderer default HRIR model */
extern const float defaultHRIR_rom_latency_s;
#ifdef FIX_989_TD_REND_ROM
extern const int16_t defaultHRIR_rom_model_configuration[6];
#else
extern const int16_t defaultHRIR_rom_azimDim2[15];
#endif
extern const int16_t defaultHRIR_rom_azimDim3[15];
extern const int16_t defaultHRIR_rom_azim_start_idx[15];
extern const int16_t defaultHRIR_rom_azimSegSamples[1];
......@@ -70,10 +66,8 @@ extern const uint32_t defaultHRIR_rom_EL32[HRTF_MODEL_N_SECTIONS * 470];
extern const uint32_t defaultHRIR_rom_ER32[HRTF_MODEL_N_SECTIONS * 470];
extern const uint32_t defaultHRIR_rom_EL16[HRTF_MODEL_N_SECTIONS * 470];
extern const uint32_t defaultHRIR_rom_ER16[HRTF_MODEL_N_SECTIONS * 470];
#ifdef FIX_989_TD_REND_ROM
extern const int16_t defaultHRIR_rom_elevBsLen[4];
extern const int16_t defaultHRIR_rom_elevBsStart[4];
#endif
extern const uint32_t defaultHRIR_rom_elevBsShape[36];
extern const uint32_t defaultHRIR_rom_azimBsShape[21];
extern const uint32_t defaultHRIR_rom_ITD_W[658];
......@@ -81,11 +75,9 @@ extern const uint32_t defaultHRIR_rom_ITD_azimBsShape[84];
extern const float defaultHRIR_rom_ITD_azimKSeq[19];
extern const uint32_t defaultHRIR_rom_ITD_elevBsShape[28];
extern const float defaultHRIR_rom_ITD_elevKSeq[16];
#ifdef FIX_989_TD_REND_ROM
extern const int16_t defaultHRIR_rom_ITD_model_configuration[4];
extern const int16_t defaultHRIR_rom_ITD_elevBsLen[4];
extern const int16_t defaultHRIR_rom_ITD_elevBsStart[4];
extern const int16_t defaultHRIR_rom_ITD_azimBsLen[4];
extern const int16_t defaultHRIR_rom_ITD_azimBsStart[4];
#endif
#endif
This diff is collapsed.
......@@ -65,8 +65,6 @@ extern float rightHRIRImag[BINAURAL_CONVBANDS][HRTF_LS_CHANNELS][BINAURAL_NTAPS]
extern float FASTCONV_HOA3_latency_s;
extern float FASTCONV_HOA2_latency_s;
extern float FASTCONV_FOA_latency_s;
extern float hrtfShCoeffsRe[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS];
extern float hrtfShCoeffsIm[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS];
/* Binaural rendering data set based on BRIRs */
......@@ -80,9 +78,13 @@ extern float rightBRIRImag[BINAURAL_CONVBANDS][HRTF_LS_CHANNELS][BINAURAL_NTAPS_
extern float fastconvReverberationTimes[CLDFB_NO_CHANNELS_MAX];
extern float fastconvReverberationEneCorrections[CLDFB_NO_CHANNELS_MAX];
/* Binaural rendering data set based on BRIRs, to be used in a combined manner
* with the above binaural rendering data set based on HRIRs for parametric
* renderer */
extern float hrtfShCoeffsRe[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS];
extern float hrtfShCoeffsIm[BINAURAL_CHANNELS][HRTF_SH_CHANNELS][HRTF_NUM_BINS];
extern const float parametricReverberationTimes[CLDFB_NO_CHANNELS_MAX];
extern const float parametricReverberationEneCorrections[CLDFB_NO_CHANNELS_MAX];
extern const float parametricEarlyPartEneCorrection[CLDFB_NO_CHANNELS_MAX];
This diff is collapsed.
This diff is collapsed.