Skip to content
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include "options.h" #include "options.h"
#include "wmc_auto.h" #include "wmc_auto.h"
#include "setup_dec_lc3.h" #include "setup_dec_lc3plus.h"
#include "functions.h" #include "functions.h"
#include <stdio.h> #include <stdio.h>
#include <assert.h> #include <assert.h>
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
#include "options.h" #include "options.h"
#include "wmc_auto.h" #include "wmc_auto.h"
#include "setup_enc_lc3.h" #include "setup_enc_lc3plus.h"
#include "functions.h" #include "functions.h"
#include <stdio.h> #include <stdio.h>
......
...@@ -482,7 +482,6 @@ static void ivas_omasa_dmx( ...@@ -482,7 +482,6 @@ static void ivas_omasa_dmx(
float g1, g2; float g1, g2;
float data_out_f[MASA_MAX_TRANSPORT_CHANNELS][L_FRAME48k]; float data_out_f[MASA_MAX_TRANSPORT_CHANNELS][L_FRAME48k];
for ( i = 0; i < nchan_transport; i++ ) for ( i = 0; i < nchan_transport; i++ )
{ {
set_zero( data_out_f[i], input_frame ); set_zero( data_out_f[i], input_frame );
...@@ -490,7 +489,6 @@ static void ivas_omasa_dmx( ...@@ -490,7 +489,6 @@ static void ivas_omasa_dmx(
for ( i = 0; i < nchan_ism; i++ ) for ( i = 0; i < nchan_ism; i++ )
{ {
#ifdef NONBE_1362_FIX_OMASA_TO_MASA1_RENDERING
if ( nchan_transport == 1 ) if ( nchan_transport == 1 )
{ {
v_add( data_out_f[0], data_in_f[i], data_out_f[0], input_frame ); v_add( data_out_f[0], data_in_f[i], data_out_f[0], input_frame );
...@@ -517,27 +515,6 @@ static void ivas_omasa_dmx( ...@@ -517,27 +515,6 @@ static void ivas_omasa_dmx(
prev_gains[i][j] = gains[j]; prev_gains[i][j] = gains[j];
} }
} }
#else
azimuth = ism_azimuth[i];
elevation = ism_elevation[i];
ivas_ism_get_stereo_gains( azimuth, elevation, &gains[0], &gains[1] );
/* Downmix using the panning gains */
for ( j = 0; j < nchan_transport; j++ )
{
if ( fabsf( gains[j] ) > 0.0 || fabsf( prev_gains[i][j] ) > 0.0f )
{
for ( k = 0; k < input_frame; k++ )
{
g1 = interpolator[k];
g2 = 1.0f - g1;
data_out_f[j][k] += ( g1 * gains[j] + g2 * prev_gains[i][j] ) * data_in_f[i][k];
}
}
prev_gains[i][j] = gains[j];
}
#endif
} }
for ( i = 0; i < nchan_transport; i++ ) for ( i = 0; i < nchan_transport; i++ )
......
...@@ -369,10 +369,75 @@ int16_t ivas_get_nchan_buffers_dec( ...@@ -369,10 +369,75 @@ int16_t ivas_get_nchan_buffers_dec(
ivas_error ivas_output_buff_dec( ivas_error ivas_output_buff_dec(
float *p_output_f[], /* i/o: output audio buffers */ float *p_output_f[], /* i/o: output audio buffers */
#ifdef FIX_1330_JBM_MEMORY
const int16_t nchan_out_buff, /* i : number of output channels */
const int16_t Opt_tsm, /* i : TSM option flag */
DECODER_TC_BUFFER_HANDLE hTcBuffer /* i : TSM buffer handle */
#else
const int16_t nchan_out_buff_old, /* i : previous frame number of output channels */ const int16_t nchan_out_buff_old, /* i : previous frame number of output channels */
const int16_t nchan_out_buff /* i : number of output channels */ const int16_t nchan_out_buff /* i : number of output channels */
#endif
) )
{ {
#ifdef FIX_1330_JBM_MEMORY
int16_t ch, nchan_tc_jbm, nsamp_to_allocate, n_samp_full, offset;
for ( ch = 0; ch < MAX_OUTPUT_CHANNELS + MAX_NUM_OBJECTS; ch++ )
{
p_output_f[ch] = NULL;
}
if ( hTcBuffer->tc_buffer2 != NULL )
{
free( hTcBuffer->tc_buffer2 );
hTcBuffer->tc_buffer2 = NULL;
}
nchan_tc_jbm = 0;
if ( Opt_tsm )
{
/* JBM decoding: output audio buffers are shared with audio buffers from 'hTcBuffer->tc[]' */
nchan_tc_jbm = max( hTcBuffer->nchan_transport_jbm, hTcBuffer->nchan_buffer_full );
}
if ( nchan_out_buff <= nchan_tc_jbm && !Opt_tsm )
{
for ( ch = 0; ch < nchan_out_buff; ch++ )
{
p_output_f[ch] = hTcBuffer->tc[ch];
}
}
else
{
for ( ch = 0; ch < nchan_tc_jbm; ch++ )
{
p_output_f[ch] = hTcBuffer->tc[ch];
}
/* non-JBM decoding: allocate output audio buffers */
/* JBM decoding: when not enough audio buffers 'hTcBuffer->tc[]', allocate additional buffers */
n_samp_full = ( 48000 / FRAMES_PER_SEC );
nsamp_to_allocate = ( nchan_out_buff - nchan_tc_jbm ) * n_samp_full;
if ( nsamp_to_allocate > 0 )
{
/* note: these are intra-frame heap memories */
if ( ( hTcBuffer->tc_buffer2 = (float *) malloc( nsamp_to_allocate * sizeof( float ) ) ) == NULL )
{
return ( IVAS_ERROR( IVAS_ERR_FAILED_ALLOC, "Can not allocate memory for floating-point output audio buffer!\n" ) );
}
set_zero( hTcBuffer->tc_buffer2, nsamp_to_allocate );
}
offset = 0;
for ( ; ch < nchan_out_buff; ch++ )
{
p_output_f[ch] = &hTcBuffer->tc_buffer2[offset];
offset += n_samp_full;
}
}
#else
int16_t ch; int16_t ch;
if ( nchan_out_buff > nchan_out_buff_old ) if ( nchan_out_buff > nchan_out_buff_old )
...@@ -400,6 +465,7 @@ ivas_error ivas_output_buff_dec( ...@@ -400,6 +465,7 @@ ivas_error ivas_output_buff_dec(
p_output_f[ch] = NULL; p_output_f[ch] = NULL;
} }
} }
#endif
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
......
...@@ -1582,6 +1582,40 @@ void ivas_rend_closeCldfbRend( ...@@ -1582,6 +1582,40 @@ void ivas_rend_closeCldfbRend(
CLDFB_REND_WRAPPER *pCldfbRend CLDFB_REND_WRAPPER *pCldfbRend
); );
/*----------------------------------------------------------------------------------*
* Time domain ring buffer prototypes
*----------------------------------------------------------------------------------*/
ivas_error ivas_TD_RINGBUF_Open(
TD_RINGBUF_HANDLE *ph, /* i/o: Ring buffer handle */
const uint32_t capacity_per_channel, /* i : Number of samples stored per channel */
const uint16_t num_channels /* i : Number of channels */
);
void ivas_TD_RINGBUF_Close(
TD_RINGBUF_HANDLE *ph /* i/o: Ring buffer handle */
);
void ivas_TD_RINGBUF_Push(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
const float *data, /* i : Input data */
const uint32_t num_samples_per_channel /* i : Number of samples per channel to store */
);
void ivas_TD_RINGBUF_PushZeros(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
const uint32_t num_samples_per_channel /* i : Number of zeros per channel to store */
);
void ivas_TD_RINGBUF_Pop(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
float *data, /* i : Output data */
const uint32_t num_samples_per_channel /* i : Number of samples per channel to retrieve*/
);
uint32_t ivas_TD_RINGBUF_Size(
const TD_RINGBUF_HANDLE h /* i : Ring buffer handle */
);
/* clang-format on */ /* clang-format on */
......
...@@ -163,15 +163,9 @@ const float ap_lattice_coeffs_3[DIRAC_DECORR_FILTER_LEN_3*DIRAC_MAX_NUM_DECORR_F ...@@ -163,15 +163,9 @@ const float ap_lattice_coeffs_3[DIRAC_DECORR_FILTER_LEN_3*DIRAC_MAX_NUM_DECORR_F
const float * const ap_lattice_coeffs[DIRAC_DECORR_NUM_SPLIT_BANDS] = const float * const ap_lattice_coeffs[DIRAC_DECORR_NUM_SPLIT_BANDS] =
{ {
#ifdef CODE_IMPROVEMENTS
ap_lattice_coeffs_1, ap_lattice_coeffs_1,
ap_lattice_coeffs_2, ap_lattice_coeffs_2,
ap_lattice_coeffs_3, ap_lattice_coeffs_3,
#else
&ap_lattice_coeffs_1[0],
&ap_lattice_coeffs_2[0],
&ap_lattice_coeffs_3[0],
#endif
}; };
const float ap_split_frequencies[DIRAC_DECORR_NUM_SPLIT_BANDS + 1] = const float ap_split_frequencies[DIRAC_DECORR_NUM_SPLIT_BANDS + 1] =
...@@ -183,11 +177,13 @@ const int16_t sba_map_tc[11] = ...@@ -183,11 +177,13 @@ const int16_t sba_map_tc[11] =
{ {
0, 1, 2, 3, 4, 8, 9, 15, 5, 6, 7 0, 1, 2, 3, 4, 8, 9, 15, 5, 6, 7
}; };
const int16_t sba_map_tc_512[11] = const int16_t sba_map_tc_512[11] =
{ {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 15 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 15
}; };
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
* FASTCONV and PARAMETRIC binaural renderer ROM tables * FASTCONV and PARAMETRIC binaural renderer ROM tables
*----------------------------------------------------------------------------------*/ *----------------------------------------------------------------------------------*/
...@@ -386,6 +382,7 @@ const float ivas_reverb_default_DSR[IVAS_REVERB_DEFAULT_N_BANDS] = ...@@ -386,6 +382,7 @@ const float ivas_reverb_default_DSR[IVAS_REVERB_DEFAULT_N_BANDS] =
6.2001e-08f, 2.8483e-08f, 2.6267e-08f 6.2001e-08f, 2.8483e-08f, 2.6267e-08f
}; };
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
* Renderer SBA & MC enc/dec matrices * Renderer SBA & MC enc/dec matrices
*----------------------------------------------------------------------------------*/ *----------------------------------------------------------------------------------*/
...@@ -394,6 +391,7 @@ const float ivas_reverb_default_DSR[IVAS_REVERB_DEFAULT_N_BANDS] = ...@@ -394,6 +391,7 @@ const float ivas_reverb_default_DSR[IVAS_REVERB_DEFAULT_N_BANDS] =
const float ls_azimuth_CICP1[1] = { 0.0f }; const float ls_azimuth_CICP1[1] = { 0.0f };
const float ls_elevation_CICP1[1] = { 0.0f }; const float ls_elevation_CICP1[1] = { 0.0f };
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
* EFAP ROM tables * EFAP ROM tables
*----------------------------------------------------------------------------------*/ *----------------------------------------------------------------------------------*/
......
...@@ -1371,6 +1371,22 @@ typedef struct ...@@ -1371,6 +1371,22 @@ typedef struct
} CLDFB_REND_WRAPPER; } CLDFB_REND_WRAPPER;
/*----------------------------------------------------------------------------------*
* Time domain ring buffer structure
*----------------------------------------------------------------------------------*/
typedef struct
{
float *data; /* samples in interleaved layout */
uint32_t capacity;
uint16_t num_channels;
uint32_t write_pos;
uint32_t read_pos;
int16_t is_full;
} TD_RINGBUF_DATA, *TD_RINGBUF_HANDLE;
/*----------------------------------------------------------------------------------* /*----------------------------------------------------------------------------------*
* MASA external renderer structure * MASA external renderer structure
*----------------------------------------------------------------------------------*/ *----------------------------------------------------------------------------------*/
......
/******************************************************************************************************
(C) 2022-2025 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB,
Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
contributors to this repository. All Rights Reserved.
This software is protected by copyright law and by international treaties.
The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB,
Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD.,
Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange,
Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other
contributors to this repository retain full ownership rights in their respective contributions in
the software. This notice grants no license of any kind, including but not limited to patent
license, nor is any license granted by implication, estoppel or otherwise.
Contributors are required to enter into the IVAS codec Public Collaboration agreement before making
contributions.
This software is provided "AS IS", without any express or implied warranties. The software is in the
development stage. It is intended exclusively for experts who have experience with such software and
solely for the purpose of inspection. All implied warranties of non-infringement, merchantability
and fitness for a particular purpose are hereby disclaimed and excluded.
Any dispute, controversy or claim arising under or in relation to providing this software shall be
submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in
accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and
the United Nations Convention on Contracts on the International Sales of Goods.
*******************************************************************************************************/
#include <assert.h>
#include <stdlib.h>
#include "ivas_error_utils.h"
#include "ivas_prot_rend.h"
#include "options.h"
#include "wmc_auto.h"
/*-----------------------------------------------------------------------*
* Local function prototypes
*-----------------------------------------------------------------------*/
static uint32_t ivas_td_ringbuf_total_size(
TD_RINGBUF_HANDLE h )
{
if ( h->is_full )
{
return h->capacity;
}
if ( h->read_pos <= h->write_pos )
{
return h->write_pos - h->read_pos;
}
/* else wrap around */
return h->write_pos + h->capacity - h->read_pos;
}
static int16_t ivas_td_ringbuf_has_space_for_num_samples(
TD_RINGBUF_HANDLE h,
const uint32_t num_samples )
{
return (int16_t) ( ivas_td_ringbuf_total_size( h ) + num_samples <= h->capacity );
}
/*-----------------------------------------------------------------------*
* Global function definitions
*-----------------------------------------------------------------------*/
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_Open()
*
* Allocate a ring buffer for TD data with the given capacity of TD samples per channel.
*
* May return IVAS_ERR_FAILED_ALLOC on failed allocation, or IVAS_ERR_OK otherwise.
*---------------------------------------------------------------------*/
ivas_error ivas_TD_RINGBUF_Open(
TD_RINGBUF_HANDLE *ph, /* i/o: Ring buffer handle */
const uint32_t capacity_per_channel, /* i : Number of samples stored per channel */
const uint16_t num_channels /* i : Number of channels */
)
{
TD_RINGBUF_HANDLE h;
uint32_t capacity;
capacity = capacity_per_channel * num_channels;
h = malloc( sizeof( TD_RINGBUF_DATA ) );
if ( h == NULL )
{
return IVAS_ERROR( IVAS_ERR_FAILED_ALLOC, "Failed to allocate memory for TD ring buffer\n" );
}
h->data = NULL;
h->capacity = 0;
h->num_channels = num_channels;
h->write_pos = 0;
h->read_pos = 0;
h->is_full = 0;
*ph = h;
h->data = malloc( capacity * sizeof( float ) );
if ( h->data == NULL )
{
return IVAS_ERROR( IVAS_ERR_FAILED_ALLOC, "Failed to allocate memory for TD ring buffer\n" );
}
h->capacity = capacity;
return IVAS_ERR_OK;
}
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_Close()
*
* Dellocate TD ring buffer. The given handle will be set to NULL.
*---------------------------------------------------------------------*/
void ivas_TD_RINGBUF_Close(
TD_RINGBUF_HANDLE *ph /* i/o: Ring buffer handle */
)
{
TD_RINGBUF_HANDLE h;
if ( ph == NULL )
{
return;
}
h = *ph;
if ( h == NULL )
{
return;
}
if ( h->data != NULL )
{
free( h->data );
}
free( h );
*ph = NULL;
return;
}
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_Push()
*
* Push samples onto the back of the TD ring buffer.
* Returns total number of buffered samples (includes number of channels)
*---------------------------------------------------------------------*/
void ivas_TD_RINGBUF_Push(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
const float *data, /* i : Input data */
const uint32_t num_samples_per_channel /* i : Number of samples per channel to store */
)
{
uint32_t s;
uint16_t c;
assert( ivas_td_ringbuf_has_space_for_num_samples( h, num_samples_per_channel * h->num_channels ) );
for ( s = 0; s < num_samples_per_channel; ++s )
{
for ( c = 0; c < h->num_channels; ++c )
{
h->data[h->write_pos] = *( data + c * num_samples_per_channel + s );
++h->write_pos;
if ( h->write_pos == h->capacity )
{
h->write_pos = 0;
}
}
}
if ( h->read_pos == h->write_pos )
{
h->is_full = 1;
}
return;
}
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_PushZeros()
*
* Push zero samples onto the back of the TD ring buffer.
*---------------------------------------------------------------------*/
void ivas_TD_RINGBUF_PushZeros(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
const uint32_t num_samples_per_channel /* i : Number of zeros per channel to store */
)
{
uint32_t s;
uint16_t c;
assert( ivas_td_ringbuf_has_space_for_num_samples( h, num_samples_per_channel * h->num_channels ) );
if ( !num_samples_per_channel )
{
return;
}
for ( s = 0; s < num_samples_per_channel; ++s )
{
for ( c = 0; c < h->num_channels; ++c )
{
h->data[h->write_pos] = 0.f;
++h->write_pos;
if ( h->write_pos == h->capacity )
{
h->write_pos = 0;
}
}
}
if ( h->read_pos == h->write_pos )
{
h->is_full = 1;
}
return;
}
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_Pop()
*
* Pop samples from the front of the TD ring buffer.
*---------------------------------------------------------------------*/
void ivas_TD_RINGBUF_Pop(
TD_RINGBUF_HANDLE h, /* i/o: Ring buffer handle */
float *data, /* i : Output data */
const uint32_t num_samples_per_channel /* i : Number of samples per channel to retrieve */
)
{
uint32_t s;
uint16_t c;
assert( ivas_td_ringbuf_total_size( h ) >= num_samples_per_channel * h->num_channels );
for ( s = 0; s < num_samples_per_channel; ++s )
{
for ( c = 0; c < h->num_channels; ++c )
{
*( data + c * num_samples_per_channel + s ) = h->data[h->read_pos];
++h->read_pos;
if ( h->read_pos == h->capacity )
{
h->read_pos = 0;
}
}
}
if ( h->is_full )
{
h->is_full = 0;
}
return;
}
/*---------------------------------------------------------------------*
* ivas_TD_RINGBUF_Size()
*
* Returns number of buffered samples per channel.
*---------------------------------------------------------------------*/
uint32_t ivas_TD_RINGBUF_Size(
const TD_RINGBUF_HANDLE h /* i : Ring buffer handle */
)
{
return ivas_td_ringbuf_total_size( h ) / (uint32_t) h->num_channels;
}
...@@ -81,6 +81,7 @@ typedef struct ...@@ -81,6 +81,7 @@ typedef struct
typedef struct typedef struct
{ {
const int32_t *pOutSampleRate; const int32_t *pOutSampleRate;
const int32_t *pMaxGlobalDelayNs;
const AUDIO_CONFIG *pOutConfig; const AUDIO_CONFIG *pOutConfig;
const LSSETUP_CUSTOM_STRUCT *pCustomLsOut; const LSSETUP_CUSTOM_STRUCT *pCustomLsOut;
const EFAP_WRAPPER *pEfapOutWrapper; const EFAP_WRAPPER *pEfapOutWrapper;
...@@ -97,9 +98,11 @@ typedef struct ...@@ -97,9 +98,11 @@ typedef struct
AUDIO_CONFIG inConfig; AUDIO_CONFIG inConfig;
IVAS_REND_InputId id; IVAS_REND_InputId id;
IVAS_REND_AudioBuffer inputBuffer; IVAS_REND_AudioBuffer inputBuffer;
TD_RINGBUF_HANDLE delayBuffer;
float gain; /* Linear, not in dB */ float gain; /* Linear, not in dB */
rendering_context ctx; rendering_context ctx;
int32_t numNewSamplesPerChannel; /* Used to keep track how much new audio was fed before rendering current frame */ int32_t numNewSamplesPerChannel; /* Used to keep track how much new audio was fed before rendering current frame */
int32_t delayNumSamples;
} input_base; } input_base;
typedef struct typedef struct
...@@ -189,6 +192,7 @@ typedef struct hrtf_handles ...@@ -189,6 +192,7 @@ typedef struct hrtf_handles
struct IVAS_REND struct IVAS_REND
{ {
int32_t sampleRateOut; int32_t sampleRateOut;
int32_t maxGlobalDelayNs;
IVAS_LIMITER_HANDLE hLimiter; IVAS_LIMITER_HANDLE hLimiter;
#ifdef DEBUGGING #ifdef DEBUGGING
...@@ -204,11 +208,12 @@ struct IVAS_REND ...@@ -204,11 +208,12 @@ struct IVAS_REND
AUDIO_CONFIG outputConfig; AUDIO_CONFIG outputConfig;
EFAP_WRAPPER efapOutWrapper; EFAP_WRAPPER efapOutWrapper;
IVAS_LSSETUP_CUSTOM_STRUCT customLsOut; IVAS_LSSETUP_CUSTOM_STRUCT customLsOut;
int16_t splitRendBFI;
SPLIT_REND_WRAPPER *splitRendWrapper; SPLIT_REND_WRAPPER *splitRendWrapper;
IVAS_REND_AudioBuffer splitRendEncBuffer; IVAS_REND_AudioBuffer splitRendEncBuffer;
IVAS_REND_HeadRotData headRotData; IVAS_REND_HeadRotData headRotData;
int16_t splitRendBFI;
EXTERNAL_ORIENTATION_HANDLE hExternalOrientationData; EXTERNAL_ORIENTATION_HANDLE hExternalOrientationData;
COMBINED_ORIENTATION_HANDLE hCombinedOrientationData; COMBINED_ORIENTATION_HANDLE hCombinedOrientationData;
...@@ -262,6 +267,13 @@ static void freeInputBaseBufferData( ...@@ -262,6 +267,13 @@ static void freeInputBaseBufferData(
return; return;
} }
static int16_t latencyNsToSamples(
int32_t sampleRate,
int32_t latency_ns )
{
return (int16_t) roundf( (float) ( latency_ns ) * ( sampleRate / 1000000000.f ) );
}
static ivas_error allocateMcLfeDelayBuffer( static ivas_error allocateMcLfeDelayBuffer(
float **lfeDelayBuffer, float **lfeDelayBuffer,
const int16_t data_size ) const int16_t data_size )
...@@ -369,7 +381,7 @@ static void copyBufferToCLDFBarray( ...@@ -369,7 +381,7 @@ static void copyBufferToCLDFBarray(
static void accumulateCLDFBArrayToBuffer( static void accumulateCLDFBArrayToBuffer(
float re[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float re[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
float im[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX], float im[][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX],
IVAS_REND_AudioBuffer *buffer ) const IVAS_REND_AudioBuffer *buffer )
{ {
uint32_t smplIdx, slotIdx; uint32_t smplIdx, slotIdx;
uint32_t numCldfbSamples, num_bands; uint32_t numCldfbSamples, num_bands;
...@@ -1162,6 +1174,8 @@ static void initRendInputBase( ...@@ -1162,6 +1174,8 @@ static void initRendInputBase(
inputBase->gain = 1.0f; inputBase->gain = 1.0f;
inputBase->ctx = rendCtx; inputBase->ctx = rendCtx;
inputBase->numNewSamplesPerChannel = 0; inputBase->numNewSamplesPerChannel = 0;
inputBase->delayNumSamples = 0;
inputBase->delayBuffer = NULL;
inputBase->inputBuffer.config.numSamplesPerChannel = 0; inputBase->inputBuffer.config.numSamplesPerChannel = 0;
inputBase->inputBuffer.config.numChannels = 0; inputBase->inputBuffer.config.numChannels = 0;
...@@ -1210,6 +1224,7 @@ static rendering_context getRendCtx( ...@@ -1210,6 +1224,7 @@ static rendering_context getRendCtx(
/* Note: when refactoring this, always take the ADDRESS of a member of the /* Note: when refactoring this, always take the ADDRESS of a member of the
* renderer struct, so that the context stores a POINTER to the member, even * renderer struct, so that the context stores a POINTER to the member, even
* if the member is a pointer or handle itself. */ * if the member is a pointer or handle itself. */
ctx.pMaxGlobalDelayNs = &hIvasRend->maxGlobalDelayNs;
ctx.pOutConfig = &hIvasRend->outputConfig; ctx.pOutConfig = &hIvasRend->outputConfig;
ctx.pOutSampleRate = &hIvasRend->sampleRateOut; ctx.pOutSampleRate = &hIvasRend->sampleRateOut;
ctx.pCustomLsOut = &hIvasRend->customLsOut; ctx.pCustomLsOut = &hIvasRend->customLsOut;
...@@ -1252,6 +1267,272 @@ static bool isIoConfigPairSupported( ...@@ -1252,6 +1267,272 @@ static bool isIoConfigPairSupported(
} }
static int32_t getRendInputDelayIsm(
const input_ism *inputIsm,
bool splitPreRendCldfb )
{
int32_t latency_ns;
latency_ns = 0;
(void) ( splitPreRendCldfb ); /* unused */
/* set the rendering delay in InputBase */
latency_ns = max( latency_ns,
inputIsm->tdRendWrapper.binaural_latency_ns );
if ( inputIsm->crendWrapper != NULL )
{
latency_ns = max( latency_ns,
inputIsm->crendWrapper->binaural_latency_ns );
}
return latency_ns;
}
static void setRendInputDelayIsm(
void *input,
bool splitPreRendCldfb )
{
input_ism *inputIsm;
inputIsm = (input_ism *) input;
inputIsm->base.delayNumSamples = latencyNsToSamples( *inputIsm->base.ctx.pOutSampleRate,
getRendInputDelayIsm( inputIsm, splitPreRendCldfb ) );
}
static int32_t getRendInputDelayMc(
const input_mc *inputMc,
bool splitPreRendCldfb )
{
int32_t latency_ns;
latency_ns = 0;
(void) ( splitPreRendCldfb ); /* unused */
latency_ns = max( latency_ns,
inputMc->tdRendWrapper.binaural_latency_ns );
if ( inputMc->crendWrapper != NULL )
{
latency_ns = max( latency_ns,
inputMc->crendWrapper->binaural_latency_ns );
}
return latency_ns;
}
static void setRendInputDelayMc(
void *input,
bool splitPreRendCldfb )
{
input_mc *inputMc;
inputMc = (input_mc *) input;
inputMc->base.delayNumSamples = latencyNsToSamples( *inputMc->base.ctx.pOutSampleRate,
getRendInputDelayMc( inputMc, splitPreRendCldfb ) );
}
static int32_t getRendInputDelaySba(
const input_sba *inputSba,
bool splitPreRendCldfb )
{
int32_t latency_ns;
latency_ns = 0;
if ( inputSba->cldfbRendWrapper.hCldfbRend != NULL )
{
latency_ns = max( latency_ns,
inputSba->cldfbRendWrapper.binaural_latency_ns +
( splitPreRendCldfb ? 0 : IVAS_FB_DEC_DELAY_NS ) );
}
if ( inputSba->crendWrapper != NULL )
{
latency_ns = max( latency_ns,
inputSba->crendWrapper->binaural_latency_ns );
}
return latency_ns;
}
static void setRendInputDelaySba(
void *input,
bool splitPreRendCldfb )
{
input_sba *inputSba;
inputSba = (input_sba *) input;
inputSba->base.delayNumSamples = latencyNsToSamples( *inputSba->base.ctx.pOutSampleRate,
getRendInputDelaySba( inputSba, splitPreRendCldfb ) );
}
static int32_t getRendInputDelayMasa(
const input_masa *inputMasa,
bool splitPreRendCldfb )
{
int32_t latency_ns;
latency_ns = 0;
if ( ( inputMasa->base.inConfig == IVAS_AUDIO_CONFIG_MASA1 && *inputMasa->base.ctx.pOutConfig == IVAS_AUDIO_CONFIG_MONO ) ||
( getAudioConfigType( *inputMasa->base.ctx.pOutConfig ) == IVAS_REND_AUDIO_CONFIG_TYPE_MASA ) )
{
return 0; /* no delay */
}
else
{
/* no delay applied for split rendering */
latency_ns = max( latency_ns,
(int32_t) ( ( splitPreRendCldfb ? 0 : (float) IVAS_FB_DEC_DELAY_NS + 0.5f ) ) );
}
return latency_ns;
}
static void setRendInputDelayMasa(
void *input,
bool splitPreRendCldfb )
{
input_masa *inputMasa;
inputMasa = (input_masa *) input;
inputMasa->base.delayNumSamples = latencyNsToSamples( *inputMasa->base.ctx.pOutSampleRate,
getRendInputDelayMasa( inputMasa, splitPreRendCldfb ) );
}
static int32_t getMaxGlobalDelayNs( IVAS_REND_CONST_HANDLE hIvasRend )
{
int16_t i;
int32_t latency_ns;
int32_t max_latency_ns;
bool splitPreRendCldfb;
max_latency_ns = 0;
/*assumes that input has been added which means codec has been set to either lcld or lc3plus (even if render config specified default)*/
if ( hIvasRend->hRendererConfig != NULL )
{
splitPreRendCldfb = ( hIvasRend->hRendererConfig->split_rend_config.codec == ISAR_SPLIT_REND_CODEC_LCLD );
}
else
{
splitPreRendCldfb = false;
}
/* Compute the maximum delay across all inputs */
for ( i = 0; i < RENDERER_MAX_ISM_INPUTS; i++ )
{
if ( hIvasRend->inputsIsm[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = getRendInputDelayIsm( &hIvasRend->inputsIsm[i], splitPreRendCldfb );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
for ( i = 0; i < RENDERER_MAX_MC_INPUTS; i++ )
{
if ( hIvasRend->inputsMc[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = getRendInputDelayMc( &hIvasRend->inputsMc[i], splitPreRendCldfb );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
for ( i = 0; i < RENDERER_MAX_SBA_INPUTS; i++ )
{
if ( hIvasRend->inputsSba[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = getRendInputDelaySba( &hIvasRend->inputsSba[i], splitPreRendCldfb );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
for ( i = 0; i < RENDERER_MAX_MASA_INPUTS; i++ )
{
if ( hIvasRend->inputsMasa[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = getRendInputDelayMasa( &hIvasRend->inputsMasa[i], splitPreRendCldfb );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
return max_latency_ns;
}
static void setMaxGlobalDelayNs( IVAS_REND_HANDLE hIvasRend )
{
hIvasRend->maxGlobalDelayNs = getMaxGlobalDelayNs( (IVAS_REND_CONST_HANDLE) hIvasRend );
}
static ivas_error alignInputDelay(
input_base *inputBase,
const IVAS_REND_ReadOnlyAudioBuffer inputAudio,
const int32_t maxGlobalDelayNs,
const int32_t sampleRateOut,
const int16_t cldfb2tdSampleFact,
const bool flushInputs )
{
ivas_error error;
input_ism *inputIsm;
int16_t maxGlobalDelaySamples;
int32_t numSamplesToPush, numSamplesToPop;
uint32_t ringBufferSize, preDelay;
maxGlobalDelaySamples = latencyNsToSamples( sampleRateOut, maxGlobalDelayNs );
maxGlobalDelaySamples *= cldfb2tdSampleFact;
/* check if we need to open the delay buffer */
if ( inputBase->delayBuffer == NULL )
{
/* buffer has to accomodate maxGlobalDelaySamples + 2 * frameSize */
ringBufferSize = maxGlobalDelaySamples + 2 * inputAudio.config.numSamplesPerChannel;
/* pre delay for this input is maximum delay - input delay */
preDelay = maxGlobalDelaySamples - inputBase->delayNumSamples * cldfb2tdSampleFact;
if ( preDelay > 0 )
{
if ( ( error = ivas_TD_RINGBUF_Open( &inputBase->delayBuffer, ringBufferSize, inputAudio.config.numChannels ) ) != IVAS_ERR_OK )
{
return error;
}
/* for the first frame we need to push zeros to align the input delay to the global delay
* and then push a frame of actual data */
ivas_TD_RINGBUF_PushZeros( inputBase->delayBuffer, preDelay );
/* for ISM inputs, ensure the metadata sync delay is updated */
if ( getAudioConfigType( inputBase->inConfig ) == IVAS_REND_AUDIO_CONFIG_TYPE_OBJECT_BASED )
{
inputIsm = (input_ism *) inputBase;
inputIsm->ism_metadata_delay_ms = maxGlobalDelayNs / 1e6f;
}
}
}
if ( inputBase->delayBuffer != NULL )
{
/* push in the new input data and pop to retrieve a complete input frame
* if we are flushing the inputs, we don't push in any new data */
numSamplesToPush = flushInputs ? 0 : inputAudio.config.numSamplesPerChannel;
numSamplesToPop = flushInputs ? ivas_TD_RINGBUF_Size( inputBase->delayBuffer ) : (uint32_t) inputAudio.config.numSamplesPerChannel;
ivas_TD_RINGBUF_Push( inputBase->delayBuffer, inputAudio.data, numSamplesToPush );
ivas_TD_RINGBUF_Pop( inputBase->delayBuffer, inputBase->inputBuffer.data, numSamplesToPop );
}
else
{
/* delay buffer isn't open - we don't need it */
mvr2r( inputAudio.data,
inputBase->inputBuffer.data,
inputAudio.config.numSamplesPerChannel * inputAudio.config.numChannels );
}
return IVAS_ERR_OK;
}
static ivas_error initIsmMasaRendering( static ivas_error initIsmMasaRendering(
input_ism *inputIsm, input_ism *inputIsm,
const int32_t inSampleRate ) const int32_t inSampleRate )
...@@ -1387,6 +1668,8 @@ static void clearInputIsm( ...@@ -1387,6 +1668,8 @@ static void clearInputIsm(
rendCtx = inputIsm->base.ctx; rendCtx = inputIsm->base.ctx;
freeInputBaseBufferData( &inputIsm->base.inputBuffer.data ); freeInputBaseBufferData( &inputIsm->base.inputBuffer.data );
ivas_TD_RINGBUF_Close( &inputIsm->base.delayBuffer );
initRendInputBase( &inputIsm->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 ); initRendInputBase( &inputIsm->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 );
/* Free input's internal handles */ /* Free input's internal handles */
...@@ -2157,7 +2440,7 @@ static ivas_error initMcBinauralRendering( ...@@ -2157,7 +2440,7 @@ static ivas_error initMcBinauralRendering(
/* determine binaural delay ( used for aligning LFE to output signal ) */ /* determine binaural delay ( used for aligning LFE to output signal ) */
binauralDelayNs = max( ( inputMc->crendWrapper != NULL ) ? inputMc->crendWrapper->binaural_latency_ns : 0, inputMc->tdRendWrapper.binaural_latency_ns ); binauralDelayNs = max( ( inputMc->crendWrapper != NULL ) ? inputMc->crendWrapper->binaural_latency_ns : 0, inputMc->tdRendWrapper.binaural_latency_ns );
inputMc->binauralDelaySmp = (int16_t) roundf( (float) binauralDelayNs * *inputMc->base.ctx.pOutSampleRate / 1000000000.f ); inputMc->binauralDelaySmp = latencyNsToSamples( *inputMc->base.ctx.pOutSampleRate, binauralDelayNs );
if ( inputMc->binauralDelaySmp > MAX_BIN_DELAY_SAMPLES ) if ( inputMc->binauralDelaySmp > MAX_BIN_DELAY_SAMPLES )
{ {
...@@ -2357,6 +2640,8 @@ static void clearInputMc( ...@@ -2357,6 +2640,8 @@ static void clearInputMc(
freeMcLfeDelayBuffer( &inputMc->lfeDelayBuffer ); freeMcLfeDelayBuffer( &inputMc->lfeDelayBuffer );
freeInputBaseBufferData( &inputMc->bufferData ); freeInputBaseBufferData( &inputMc->bufferData );
ivas_TD_RINGBUF_Close( &inputMc->base.delayBuffer );
initRendInputBase( &inputMc->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 ); initRendInputBase( &inputMc->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 );
/* Free input's internal handles */ /* Free input's internal handles */
...@@ -2644,7 +2929,7 @@ static ivas_error setRendInputActiveSba( ...@@ -2644,7 +2929,7 @@ static ivas_error setRendInputActiveSba(
return error; return error;
} }
return error; return IVAS_ERR_OK;
} }
...@@ -2656,6 +2941,7 @@ static void clearInputSba( ...@@ -2656,6 +2941,7 @@ static void clearInputSba(
rendCtx = inputSba->base.ctx; rendCtx = inputSba->base.ctx;
freeInputBaseBufferData( &inputSba->bufferData ); freeInputBaseBufferData( &inputSba->bufferData );
ivas_TD_RINGBUF_Close( &inputSba->base.delayBuffer );
initRendInputBase( &inputSba->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 ); initRendInputBase( &inputSba->base, IVAS_AUDIO_CONFIG_INVALID, 0, rendCtx, NULL, 0 );
...@@ -2735,6 +3021,7 @@ static void clearInputMasa( ...@@ -2735,6 +3021,7 @@ static void clearInputMasa(
rendCtx = inputMasa->base.ctx; rendCtx = inputMasa->base.ctx;
freeInputBaseBufferData( &inputMasa->bufferData ); freeInputBaseBufferData( &inputMasa->bufferData );
ivas_TD_RINGBUF_Close( &inputMasa->base.delayBuffer );
masaPrerendClose( &inputMasa->hMasaPrerend ); masaPrerendClose( &inputMasa->hMasaPrerend );
freeMasaExtRenderer( &inputMasa->hMasaExtRend ); freeMasaExtRenderer( &inputMasa->hMasaExtRend );
...@@ -2804,7 +3091,7 @@ ivas_error IVAS_REND_Open( ...@@ -2804,7 +3091,7 @@ ivas_error IVAS_REND_Open(
hIvasRend->num_subframes = num_subframes; hIvasRend->num_subframes = num_subframes;
/* Initialize limiter */ /* Initialize limiter */
if ( ( error = IVAS_REND_NumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK ) if ( ( error = IVAS_REND_GetNumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK )
{ {
return error; return error;
} }
...@@ -2863,6 +3150,9 @@ ivas_error IVAS_REND_Open( ...@@ -2863,6 +3150,9 @@ ivas_error IVAS_REND_Open(
isar_init_split_rend_handles( hIvasRend->splitRendWrapper ); isar_init_split_rend_handles( hIvasRend->splitRendWrapper );
} }
hIvasRend->splitRendEncBuffer.data = NULL; hIvasRend->splitRendEncBuffer.data = NULL;
hIvasRend->splitRendEncBuffer.config.is_cldfb = 0;
hIvasRend->splitRendEncBuffer.config.numChannels = 0;
hIvasRend->splitRendEncBuffer.config.numSamplesPerChannel = 0;
for ( i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i ) for ( i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i )
{ {
...@@ -3058,7 +3348,7 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout( ...@@ -3058,7 +3348,7 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout(
hIvasRend->customLsOut = makeCustomLsSetup( layout ); hIvasRend->customLsOut = makeCustomLsSetup( layout );
/* Re-initialize limiter - number of output channels may have changed */ /* Re-initialize limiter - number of output channels may have changed */
if ( ( error = IVAS_REND_NumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK ) if ( ( error = IVAS_REND_GetNumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK )
{ {
return error; return error;
} }
...@@ -3116,12 +3406,12 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout( ...@@ -3116,12 +3406,12 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout(
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* IVAS_REND_NumOutChannels() * IVAS_REND_GetNumOutChannels()
* *
* *
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
ivas_error IVAS_REND_NumOutChannels( ivas_error IVAS_REND_GetNumOutChannels(
IVAS_REND_CONST_HANDLE hIvasRend, IVAS_REND_CONST_HANDLE hIvasRend,
int16_t *numOutChannels ) int16_t *numOutChannels )
{ {
...@@ -3291,7 +3581,7 @@ static ivas_error getConstInputById( ...@@ -3291,7 +3581,7 @@ static ivas_error getConstInputById(
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
#ifdef CODE_IMPROVEMENTS
static void *getInputByIndex( static void *getInputByIndex(
void *inputsArray, void *inputsArray,
const size_t index, const size_t index,
...@@ -3317,56 +3607,30 @@ static void *getInputByIndex( ...@@ -3317,56 +3607,30 @@ static void *getInputByIndex(
/* include a final return to make the linter happy and avoid problems with wmc_tool (see #1355) */ /* include a final return to make the linter happy and avoid problems with wmc_tool (see #1355) */
return NULL; return NULL;
} }
#endif
static ivas_error findFreeInputSlot( static ivas_error findFreeInputSlot(
#ifdef CODE_IMPROVEMENTS
void *inputs, void *inputs,
const IVAS_REND_AudioConfigType inputType, const IVAS_REND_AudioConfigType inputType,
#else
const void *inputs,
const int32_t inputStructSize,
#endif
const int32_t maxInputs, const int32_t maxInputs,
int32_t *inputIndex ) int32_t *inputIndex )
{ {
#ifdef CODE_IMPROVEMENTS
/* Using a void pointer and a separately provided type is a hack for this function /* Using a void pointer and a separately provided type is a hack for this function
to be reusable for arrays of any input type (input_ism, input_mc, input_sba, input_masa). to be reusable for arrays of any input type (input_ism, input_mc, input_sba, input_masa).
Assumptions: Assumptions:
- input_base is always the first member in the input struct - input_base is always the first member in the input struct
- memory alignments of original input type and input_base are the same - memory alignments of original input type and input_base are the same
*/ */
#else
/* Using a void pointer and a separately provided size is a hack for this function
to be reusable for arrays of any input type (input_ism, input_mc, input_sba, input_masa).
Assumptions:
- input_base is always the first member in the input struct
- provided size is correct
*/
#endif
int32_t i; int32_t i;
bool canAddInput; bool canAddInput;
#ifndef CODE_IMPROVEMENTS
const uint8_t *pByte;
#endif
const input_base *pInputBase; const input_base *pInputBase;
canAddInput = false; canAddInput = false;
/* Find first unused input in array */ /* Find first unused input in array */
#ifdef CODE_IMPROVEMENTS
for ( i = 0; i < maxInputs; ++i ) for ( i = 0; i < maxInputs; ++i )
#else
for ( i = 0, pByte = inputs; i < maxInputs; ++i, pByte += inputStructSize )
#endif
{ {
#ifdef CODE_IMPROVEMENTS
pInputBase = (const input_base *) getInputByIndex( inputs, i, inputType ); pInputBase = (const input_base *) getInputByIndex( inputs, i, inputType );
#else
pInputBase = (const input_base *) pByte;
#endif
if ( pInputBase->inConfig == IVAS_AUDIO_CONFIG_INVALID ) if ( pInputBase->inConfig == IVAS_AUDIO_CONFIG_INVALID )
{ {
...@@ -3396,10 +3660,15 @@ static int16_t getCldfbRendFlag( ...@@ -3396,10 +3660,15 @@ static int16_t getCldfbRendFlag(
const IVAS_REND_AudioConfigType new_configType ) const IVAS_REND_AudioConfigType new_configType )
{ {
int16_t i; int16_t i;
int16_t numMasaInputs = 0, numSbaInputs = 0, numIsmInputs = 0, numMcInputs = 0; int16_t numMasaInputs = 0, numSbaInputs = 0;
int16_t isCldfbRend; int16_t isCldfbRend;
isCldfbRend = 0; isCldfbRend = 0;
/* This function is called during three different phases of renderer processing:
* - IVAS_REND_AddInput()
* - IVAS_REND_FeedRenderConfig()
* - IVAS_REND_GetSplitBinauralBitstream()
* Only the last case can assume all inputs are present for the current frame to be rendered */
if ( hIvasRend->hRendererConfig != NULL ) if ( hIvasRend->hRendererConfig != NULL )
{ {
for ( i = 0; i < RENDERER_MAX_MASA_INPUTS; ++i ) for ( i = 0; i < RENDERER_MAX_MASA_INPUTS; ++i )
...@@ -3410,20 +3679,7 @@ static int16_t getCldfbRendFlag( ...@@ -3410,20 +3679,7 @@ static int16_t getCldfbRendFlag(
{ {
numSbaInputs += ( hIvasRend->inputsSba[i].base.inConfig == IVAS_AUDIO_CONFIG_INVALID && new_configType != IVAS_REND_AUDIO_CONFIG_TYPE_AMBISONICS ) ? 0 : 1; numSbaInputs += ( hIvasRend->inputsSba[i].base.inConfig == IVAS_AUDIO_CONFIG_INVALID && new_configType != IVAS_REND_AUDIO_CONFIG_TYPE_AMBISONICS ) ? 0 : 1;
} }
for ( i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i ) if ( ( numMasaInputs > 0 ) || ( numSbaInputs > 0 && hIvasRend->hRendererConfig->split_rend_config.rendererSelection == IVAS_BIN_RENDERER_TYPE_FASTCONV ) )
{
numIsmInputs += ( hIvasRend->inputsIsm[i].base.inConfig == IVAS_AUDIO_CONFIG_INVALID && new_configType != IVAS_REND_AUDIO_CONFIG_TYPE_OBJECT_BASED ) ? 0 : 1;
}
for ( i = 0; i < RENDERER_MAX_MC_INPUTS; ++i )
{
numMcInputs += ( hIvasRend->inputsMc[i].base.inConfig == IVAS_AUDIO_CONFIG_INVALID && new_configType != IVAS_REND_AUDIO_CONFIG_TYPE_CHANNEL_BASED ) ? 0 : 1;
}
if ( numIsmInputs > 0 || numMcInputs > 0 )
{
isCldfbRend = 0;
}
else if ( ( numMasaInputs > 0 ) || ( numSbaInputs > 0 && hIvasRend->hRendererConfig->split_rend_config.rendererSelection == IVAS_BIN_RENDERER_TYPE_FASTCONV ) )
{ {
isCldfbRend = 1; isCldfbRend = 1;
} }
...@@ -3433,12 +3689,12 @@ static int16_t getCldfbRendFlag( ...@@ -3433,12 +3689,12 @@ static int16_t getCldfbRendFlag(
} }
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------
* Function ivas_pre_rend_init() * Function isar_pre_rend_init()
* *
* *
*------------------------------------------------------------------------*/ *------------------------------------------------------------------------*/
static ivas_error ivas_pre_rend_init( static ivas_error isar_pre_rend_init(
SPLIT_REND_WRAPPER *pSplitRendWrapper, SPLIT_REND_WRAPPER *pSplitRendWrapper,
IVAS_REND_AudioBuffer *pSplitRendEncBuffer, IVAS_REND_AudioBuffer *pSplitRendEncBuffer,
ISAR_SPLIT_REND_CONFIG_DATA *pSplit_rend_config, ISAR_SPLIT_REND_CONFIG_DATA *pSplit_rend_config,
...@@ -3448,10 +3704,20 @@ static ivas_error ivas_pre_rend_init( ...@@ -3448,10 +3704,20 @@ static ivas_error ivas_pre_rend_init(
const int16_t cldfb_in_flag, const int16_t cldfb_in_flag,
const int16_t num_subframes ) const int16_t num_subframes )
{ {
bool realloc;
ivas_error error; ivas_error error;
IVAS_REND_AudioBufferConfig bufConfig; IVAS_REND_AudioBufferConfig bufConfig;
if ( outConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || outConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) realloc = false;
/* only perform init if split rendering output */
if ( outConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && outConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
{
return IVAS_ERR_OK;
}
/* these functions should only be called once during initial allocation */
if ( pSplitRendEncBuffer->data == NULL )
{ {
if ( pSplit_rend_config->poseCorrectionMode == ISAR_SPLIT_REND_POSE_CORRECTION_MODE_CLDFB ) if ( pSplit_rend_config->poseCorrectionMode == ISAR_SPLIT_REND_POSE_CORRECTION_MODE_CLDFB )
{ {
...@@ -3466,28 +3732,34 @@ static ivas_error ivas_pre_rend_init( ...@@ -3466,28 +3732,34 @@ static ivas_error ivas_pre_rend_init(
{ {
return error; return error;
} }
}
/* We may need to change the allocated buffer size if a new input is added.
* If the cldfb_in_flag is different from what was previously allocated for the buffer, change the size */
if ( pSplitRendEncBuffer->data != NULL && ( cldfb_in_flag != pSplitRendEncBuffer->config.is_cldfb ) )
{
realloc = true;
}
/*allocate for CLDFB in and change to TD during process if needed*/ if ( pSplitRendEncBuffer->data == NULL || realloc )
bufConfig.numSamplesPerChannel = MAX_CLDFB_BUFFER_LENGTH_PER_CHANNEL; {
/* set buffer config */
bufConfig.is_cldfb = cldfb_in_flag;
bufConfig.numSamplesPerChannel = cldfb_in_flag ? MAX_CLDFB_BUFFER_LENGTH_PER_CHANNEL : L_FRAME_MAX;
bufConfig.numChannels = BINAURAL_CHANNELS * pSplitRendWrapper->multiBinPoseData.num_poses; bufConfig.numChannels = BINAURAL_CHANNELS * pSplitRendWrapper->multiBinPoseData.num_poses;
bufConfig.is_cldfb = 1;
pSplitRendEncBuffer->config = bufConfig; pSplitRendEncBuffer->config = bufConfig;
/* allocate memory */
if ( realloc )
{
free( pSplitRendEncBuffer->data );
}
if ( ( pSplitRendEncBuffer->data = malloc( bufConfig.numChannels * bufConfig.numSamplesPerChannel * sizeof( float ) ) ) == NULL ) if ( ( pSplitRendEncBuffer->data = malloc( bufConfig.numChannels * bufConfig.numSamplesPerChannel * sizeof( float ) ) ) == NULL )
{ {
return IVAS_ERR_FAILED_ALLOC; return IVAS_ERR_FAILED_ALLOC;
} }
} }
else
{
IVAS_REND_AudioBufferConfig bufConfig2;
bufConfig2.numSamplesPerChannel = 0;
bufConfig2.numChannels = 0;
bufConfig2.is_cldfb = 0;
pSplitRendEncBuffer->config = bufConfig2;
pSplitRendEncBuffer->data = NULL;
}
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
...@@ -3508,13 +3780,13 @@ ivas_error IVAS_REND_AddInput( ...@@ -3508,13 +3780,13 @@ ivas_error IVAS_REND_AddInput(
ivas_error error; ivas_error error;
int32_t maxNumInputsOfType; int32_t maxNumInputsOfType;
void *inputsArray; void *inputsArray;
#ifdef CODE_IMPROVEMENTS
IVAS_REND_AudioConfigType inputType; IVAS_REND_AudioConfigType inputType;
#else
int32_t inputStructSize;
#endif
ivas_error ( *activateInput )( void *, AUDIO_CONFIG, IVAS_REND_InputId, RENDER_CONFIG_DATA *, hrtf_handles * ); ivas_error ( *activateInput )( void *, AUDIO_CONFIG, IVAS_REND_InputId, RENDER_CONFIG_DATA *, hrtf_handles * );
void ( *setInputDelay )( void *, bool );
int32_t inputIndex; int32_t inputIndex;
bool splitPreRendCldfb;
splitPreRendCldfb = false;
/* Validate function arguments */ /* Validate function arguments */
if ( hIvasRend == NULL || inputId == NULL ) if ( hIvasRend == NULL || inputId == NULL )
...@@ -3522,80 +3794,75 @@ ivas_error IVAS_REND_AddInput( ...@@ -3522,80 +3794,75 @@ ivas_error IVAS_REND_AddInput(
return IVAS_ERR_UNEXPECTED_NULL_POINTER; return IVAS_ERR_UNEXPECTED_NULL_POINTER;
} }
if ( ( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) && hIvasRend->splitRendEncBuffer.data == NULL && hIvasRend->hRendererConfig != NULL ) if ( hIvasRend->hRendererConfig != NULL )
{ {
int16_t cldfb_in_flag; int16_t cldfb_in_flag;
cldfb_in_flag = getCldfbRendFlag( hIvasRend, getAudioConfigType( inConfig ) ); cldfb_in_flag = getCldfbRendFlag( hIvasRend, getAudioConfigType( inConfig ) );
if ( ( error = ivas_pre_rend_init( hIvasRend->splitRendWrapper, &hIvasRend->splitRendEncBuffer, &hIvasRend->hRendererConfig->split_rend_config, hIvasRend->headRotData, hIvasRend->sampleRateOut, hIvasRend->outputConfig, cldfb_in_flag, hIvasRend->num_subframes ) ) != IVAS_ERR_OK ) if ( ( error = isar_pre_rend_init( hIvasRend->splitRendWrapper,
&hIvasRend->splitRendEncBuffer,
&hIvasRend->hRendererConfig->split_rend_config,
hIvasRend->headRotData,
hIvasRend->sampleRateOut,
hIvasRend->outputConfig,
cldfb_in_flag,
hIvasRend->num_subframes ) ) != IVAS_ERR_OK )
{ {
return error; return error;
} }
/*assumes that input has been added which means codec has been set to either lcld or lc3plus (even if render config specified default)*/
splitPreRendCldfb = ( hIvasRend->hRendererConfig->split_rend_config.codec == ISAR_SPLIT_REND_CODEC_LCLD );
} }
#ifdef CODE_IMPROVEMENTS
inputType = getAudioConfigType( inConfig ); inputType = getAudioConfigType( inConfig );
switch ( inputType ) switch ( inputType )
#else
switch ( getAudioConfigType( inConfig ) )
#endif
{ {
case IVAS_REND_AUDIO_CONFIG_TYPE_OBJECT_BASED: case IVAS_REND_AUDIO_CONFIG_TYPE_OBJECT_BASED:
maxNumInputsOfType = RENDERER_MAX_ISM_INPUTS; maxNumInputsOfType = RENDERER_MAX_ISM_INPUTS;
inputsArray = hIvasRend->inputsIsm; inputsArray = hIvasRend->inputsIsm;
#ifndef CODE_IMPROVEMENTS
inputStructSize = sizeof( *hIvasRend->inputsIsm );
#endif
activateInput = setRendInputActiveIsm; activateInput = setRendInputActiveIsm;
setInputDelay = setRendInputDelayIsm;
break; break;
case IVAS_REND_AUDIO_CONFIG_TYPE_CHANNEL_BASED: case IVAS_REND_AUDIO_CONFIG_TYPE_CHANNEL_BASED:
maxNumInputsOfType = RENDERER_MAX_MC_INPUTS; maxNumInputsOfType = RENDERER_MAX_MC_INPUTS;
inputsArray = hIvasRend->inputsMc; inputsArray = hIvasRend->inputsMc;
#ifndef CODE_IMPROVEMENTS
inputStructSize = sizeof( *hIvasRend->inputsMc );
#endif
activateInput = setRendInputActiveMc; activateInput = setRendInputActiveMc;
setInputDelay = setRendInputDelayMc;
break; break;
case IVAS_REND_AUDIO_CONFIG_TYPE_AMBISONICS: case IVAS_REND_AUDIO_CONFIG_TYPE_AMBISONICS:
maxNumInputsOfType = RENDERER_MAX_SBA_INPUTS; maxNumInputsOfType = RENDERER_MAX_SBA_INPUTS;
inputsArray = hIvasRend->inputsSba; inputsArray = hIvasRend->inputsSba;
#ifndef CODE_IMPROVEMENTS
inputStructSize = sizeof( *hIvasRend->inputsSba );
#endif
activateInput = setRendInputActiveSba; activateInput = setRendInputActiveSba;
setInputDelay = setRendInputDelaySba;
break; break;
case IVAS_REND_AUDIO_CONFIG_TYPE_MASA: case IVAS_REND_AUDIO_CONFIG_TYPE_MASA:
maxNumInputsOfType = RENDERER_MAX_MASA_INPUTS; maxNumInputsOfType = RENDERER_MAX_MASA_INPUTS;
inputsArray = hIvasRend->inputsMasa; inputsArray = hIvasRend->inputsMasa;
#ifndef CODE_IMPROVEMENTS
inputStructSize = sizeof( *hIvasRend->inputsMasa );
#endif
activateInput = setRendInputActiveMasa; activateInput = setRendInputActiveMasa;
setInputDelay = setRendInputDelayMasa;
break; break;
default: default:
return IVAS_ERR_INVALID_INPUT_FORMAT; return IVAS_ERR_INVALID_INPUT_FORMAT;
} }
/* Find first free input in array corresponding to input type */ /* Find first free input in array corresponding to input type */
#ifdef CODE_IMPROVEMENTS
if ( ( error = findFreeInputSlot( inputsArray, inputType, maxNumInputsOfType, &inputIndex ) ) != IVAS_ERR_OK ) if ( ( error = findFreeInputSlot( inputsArray, inputType, maxNumInputsOfType, &inputIndex ) ) != IVAS_ERR_OK )
#else
if ( ( error = findFreeInputSlot( inputsArray, inputStructSize, maxNumInputsOfType, &inputIndex ) ) != IVAS_ERR_OK )
#endif
{ {
return error; return error;
} }
*inputId = makeInputId( inConfig, inputIndex ); *inputId = makeInputId( inConfig, inputIndex );
#ifdef CODE_IMPROVEMENTS
if ( ( error = activateInput( getInputByIndex( inputsArray, inputIndex, inputType ), inConfig, *inputId, hIvasRend->hRendererConfig, &hIvasRend->hHrtfs ) ) != IVAS_ERR_OK ) if ( ( error = activateInput( getInputByIndex( inputsArray, inputIndex, inputType ), inConfig, *inputId, hIvasRend->hRendererConfig, &hIvasRend->hHrtfs ) ) != IVAS_ERR_OK )
#else
if ( ( error = activateInput( (uint8_t *) inputsArray + inputStructSize * inputIndex, inConfig, *inputId, hIvasRend->hRendererConfig, &hIvasRend->hHrtfs ) ) != IVAS_ERR_OK )
#endif
{ {
return error; return error;
} }
setInputDelay( getInputByIndex( inputsArray, inputIndex, inputType ), splitPreRendCldfb );
/* set global maximum delay after adding an input */
setMaxGlobalDelayNs( hIvasRend );
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
...@@ -3848,6 +4115,9 @@ ivas_error IVAS_REND_RemoveInput( ...@@ -3848,6 +4115,9 @@ ivas_error IVAS_REND_RemoveInput(
return IVAS_ERR_INVALID_INPUT_FORMAT; return IVAS_ERR_INVALID_INPUT_FORMAT;
} }
/* set global maximum delay after removing an input */
setMaxGlobalDelayNs( hIvasRend );
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
...@@ -3924,11 +4194,6 @@ ivas_error IVAS_REND_GetDelay( ...@@ -3924,11 +4194,6 @@ ivas_error IVAS_REND_GetDelay(
int32_t *timeScale /* o : Time scale of the delay, equal to renderer output sampling rate */ int32_t *timeScale /* o : Time scale of the delay, equal to renderer output sampling rate */
) )
{ {
/* TODO tmu : this function only returns the maximum delay across all inputs
* Ideally each input has its own delay buffer and everything is aligned (binaural and LFE filtering delays are nonuniform)
*/
int16_t i;
int32_t latency_ns;
int32_t max_latency_ns; int32_t max_latency_ns;
/* Validate function arguments */ /* Validate function arguments */
...@@ -3937,76 +4202,16 @@ ivas_error IVAS_REND_GetDelay( ...@@ -3937,76 +4202,16 @@ ivas_error IVAS_REND_GetDelay(
return IVAS_ERR_UNEXPECTED_NULL_POINTER; return IVAS_ERR_UNEXPECTED_NULL_POINTER;
} }
*timeScale = hIvasRend->sampleRateOut;
*nSamples = 0; *nSamples = 0;
max_latency_ns = 0; *timeScale = hIvasRend->sampleRateOut;
/* Compute the maximum delay across all inputs */
for ( i = 0; i < RENDERER_MAX_ISM_INPUTS; i++ )
{
if ( hIvasRend->inputsIsm[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = max( ( hIvasRend->inputsIsm[i].crendWrapper != NULL ) ? hIvasRend->inputsIsm[i].crendWrapper->binaural_latency_ns : 0,
hIvasRend->inputsIsm[i].tdRendWrapper.binaural_latency_ns );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
for ( i = 0; i < RENDERER_MAX_MC_INPUTS; i++ )
{
if ( hIvasRend->inputsMc[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = max( ( hIvasRend->inputsMc[i].crendWrapper != NULL ) ? hIvasRend->inputsMc[i].crendWrapper->binaural_latency_ns : 0,
hIvasRend->inputsMc[i].tdRendWrapper.binaural_latency_ns );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
for ( i = 0; i < RENDERER_MAX_SBA_INPUTS; i++ )
{
if ( hIvasRend->inputsSba[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
if ( hIvasRend->splitRendWrapper != NULL && hIvasRend->splitRendWrapper->hBinHrSplitPreRend != NULL )
{
if ( hIvasRend->hRendererConfig->split_rend_config.rendererSelection == IVAS_BIN_RENDERER_TYPE_FASTCONV )
{
latency_ns = hIvasRend->inputsSba[i].cldfbRendWrapper.binaural_latency_ns;
}
else
{
latency_ns = ( hIvasRend->inputsSba[i].crendWrapper != NULL ) ? hIvasRend->inputsSba[i].crendWrapper->binaural_latency_ns : 0;
}
max_latency_ns = max( max_latency_ns, latency_ns );
}
else if ( hIvasRend->inputsSba[i].cldfbRendWrapper.hCldfbRend != NULL )
{
latency_ns = hIvasRend->inputsSba[i].cldfbRendWrapper.binaural_latency_ns;
latency_ns += IVAS_FB_DEC_DELAY_NS;
max_latency_ns = max( max_latency_ns, latency_ns );
}
else
{
latency_ns = ( hIvasRend->inputsSba[i].crendWrapper != NULL ) ? hIvasRend->inputsSba[i].crendWrapper->binaural_latency_ns : 0;
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
}
for ( i = 0; i < RENDERER_MAX_MASA_INPUTS; i++ ) max_latency_ns = getMaxGlobalDelayNs( hIvasRend );
{
if ( hIvasRend->inputsMasa[i].base.inConfig != IVAS_AUDIO_CONFIG_INVALID )
{
latency_ns = (int32_t) ( (float) IVAS_FB_DEC_DELAY_NS + 0.5f );
max_latency_ns = max( max_latency_ns, latency_ns );
}
}
*nSamples = (int16_t) roundf( (float) max_latency_ns * *timeScale / 1000000000.f ); *nSamples = latencyNsToSamples( hIvasRend->sampleRateOut, max_latency_ns );
return IVAS_ERR_OK; return IVAS_ERR_OK;
} }
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* IVAS_REND_FeedInputAudio() * IVAS_REND_FeedInputAudio()
* *
...@@ -4016,7 +4221,8 @@ ivas_error IVAS_REND_GetDelay( ...@@ -4016,7 +4221,8 @@ ivas_error IVAS_REND_GetDelay(
ivas_error IVAS_REND_FeedInputAudio( ivas_error IVAS_REND_FeedInputAudio(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */ IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
const IVAS_REND_InputId inputId, /* i : ID of the input */ const IVAS_REND_InputId inputId, /* i : ID of the input */
const IVAS_REND_ReadOnlyAudioBuffer inputAudio /* i : buffer with input audio */ const IVAS_REND_ReadOnlyAudioBuffer inputAudio, /* i : buffer with input audio */
const bool flushInputs /* i : flush input audio */
) )
{ {
ivas_error error; ivas_error error;
...@@ -4072,9 +4278,16 @@ ivas_error IVAS_REND_FeedInputAudio( ...@@ -4072,9 +4278,16 @@ ivas_error IVAS_REND_FeedInputAudio(
} }
inputBase->inputBuffer.config = inputAudio.config; inputBase->inputBuffer.config = inputAudio.config;
if ( ( error = alignInputDelay(
mvr2r( inputAudio.data, inputBase->inputBuffer.data, inputAudio.config.numSamplesPerChannel * inputAudio.config.numChannels ); inputBase,
inputAudio,
hIvasRend->maxGlobalDelayNs,
hIvasRend->sampleRateOut,
cldfb2tdSampleFact,
flushInputs ) ) != IVAS_ERR_OK )
{
return error;
}
inputBase->numNewSamplesPerChannel = inputAudio.config.numSamplesPerChannel / cldfb2tdSampleFact; inputBase->numNewSamplesPerChannel = inputAudio.config.numSamplesPerChannel / cldfb2tdSampleFact;
return IVAS_ERR_OK; return IVAS_ERR_OK;
...@@ -4382,6 +4595,7 @@ ivas_error IVAS_REND_FeedRenderConfig( ...@@ -4382,6 +4595,7 @@ ivas_error IVAS_REND_FeedRenderConfig(
if ( pMasaInput->hMasaExtRend->hDiracDecBin[0] != NULL && pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb != NULL ) if ( pMasaInput->hMasaExtRend->hDiracDecBin[0] != NULL && pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb != NULL )
{ {
ivas_binaural_reverb_close( &pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb ); ivas_binaural_reverb_close( &pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb );
if ( ( error = ivas_binaural_reverb_init( &pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb, if ( ( error = ivas_binaural_reverb_init( &pMasaInput->hMasaExtRend->hDiracDecBin[0]->hReverb,
hIvasRend->hHrtfs.hHrtfStatistics, hIvasRend->hHrtfs.hHrtfStatistics,
pMasaInput->hMasaExtRend->hSpatParamRendCom->num_freq_bands, pMasaInput->hMasaExtRend->hSpatParamRendCom->num_freq_bands,
...@@ -4399,6 +4613,7 @@ ivas_error IVAS_REND_FeedRenderConfig( ...@@ -4399,6 +4613,7 @@ ivas_error IVAS_REND_FeedRenderConfig(
if ( pMasaInput->hMasaExtRend->hReverb != NULL ) if ( pMasaInput->hMasaExtRend->hReverb != NULL )
{ {
ivas_binaural_reverb_close( &pMasaInput->hMasaExtRend->hReverb ); ivas_binaural_reverb_close( &pMasaInput->hMasaExtRend->hReverb );
if ( ( error = ivas_binaural_reverb_init( &pMasaInput->hMasaExtRend->hReverb, if ( ( error = ivas_binaural_reverb_init( &pMasaInput->hMasaExtRend->hReverb,
hIvasRend->hHrtfs.hHrtfStatistics, hIvasRend->hHrtfs.hHrtfStatistics,
pMasaInput->hMasaExtRend->hSpatParamRendCom->num_freq_bands, pMasaInput->hMasaExtRend->hSpatParamRendCom->num_freq_bands,
...@@ -4431,6 +4646,7 @@ ivas_error IVAS_REND_FeedRenderConfig( ...@@ -4431,6 +4646,7 @@ ivas_error IVAS_REND_FeedRenderConfig(
return error; return error;
} }
} }
if ( pMcInput->crendWrapper != NULL && pMcInput->crendWrapper->hCrend[0] && pMcInput->crendWrapper->hCrend[0]->hReverb != NULL ) if ( pMcInput->crendWrapper != NULL && pMcInput->crendWrapper->hCrend[0] && pMcInput->crendWrapper->hCrend[0]->hReverb != NULL )
{ {
if ( ( error = ivas_reverb_open( &pMcInput->crendWrapper->hCrend[0]->hReverb, hIvasRend->hHrtfs.hHrtfStatistics, hRenderConfig, *pMcInput->base.ctx.pOutSampleRate ) ) != IVAS_ERR_OK ) if ( ( error = ivas_reverb_open( &pMcInput->crendWrapper->hCrend[0]->hReverb, hIvasRend->hHrtfs.hHrtfStatistics, hRenderConfig, *pMcInput->base.ctx.pOutSampleRate ) ) != IVAS_ERR_OK )
...@@ -4481,6 +4697,7 @@ ivas_error IVAS_REND_FeedRenderConfig( ...@@ -4481,6 +4697,7 @@ ivas_error IVAS_REND_FeedRenderConfig(
{ {
int16_t cldfb_in_flag; int16_t cldfb_in_flag;
cldfb_in_flag = getCldfbRendFlag( hIvasRend, IVAS_REND_AUDIO_CONFIG_TYPE_UNKNOWN ); cldfb_in_flag = getCldfbRendFlag( hIvasRend, IVAS_REND_AUDIO_CONFIG_TYPE_UNKNOWN );
if ( hIvasRend->splitRendWrapper != NULL ) if ( hIvasRend->splitRendWrapper != NULL )
{ {
ISAR_PRE_REND_close( hIvasRend->splitRendWrapper, &hIvasRend->splitRendEncBuffer ); ISAR_PRE_REND_close( hIvasRend->splitRendWrapper, &hIvasRend->splitRendEncBuffer );
...@@ -4488,7 +4705,7 @@ ivas_error IVAS_REND_FeedRenderConfig( ...@@ -4488,7 +4705,7 @@ ivas_error IVAS_REND_FeedRenderConfig(
hIvasRend->splitRendWrapper = NULL; hIvasRend->splitRendWrapper = NULL;
} }
if ( ( error = ivas_pre_rend_init( hIvasRend->splitRendWrapper, &hIvasRend->splitRendEncBuffer, &hIvasRend->hRendererConfig->split_rend_config, hIvasRend->headRotData, hIvasRend->sampleRateOut, hIvasRend->outputConfig, cldfb_in_flag, hIvasRend->num_subframes ) ) != IVAS_ERR_OK ) if ( ( error = isar_pre_rend_init( hIvasRend->splitRendWrapper, &hIvasRend->splitRendEncBuffer, &hIvasRend->hRendererConfig->split_rend_config, hIvasRend->headRotData, hIvasRend->sampleRateOut, hIvasRend->outputConfig, cldfb_in_flag, hIvasRend->num_subframes ) ) != IVAS_ERR_OK )
{ {
return error; return error;
} }
...@@ -5217,7 +5434,7 @@ static ivas_error renderIsmToBinaural( ...@@ -5217,7 +5434,7 @@ static ivas_error renderIsmToBinaural(
push_wmops( "renderIsmToBinaural" ); push_wmops( "renderIsmToBinaural" );
/* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */ /* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */
ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000 / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) ); ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000.f / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) );
copyBufferTo2dArray( ismInput->base.inputBuffer, tmpTDRendBuffer ); copyBufferTo2dArray( ismInput->base.inputBuffer, tmpTDRendBuffer );
if ( ( error = ivas_td_binaural_renderer_ext( &ismInput->tdRendWrapper, ismInput->base.inConfig, NULL, ismInput->base.ctx.pCombinedOrientationData, &ismInput->currentPos, ismInput->hReverb, ism_md_subframe_update_ext, if ( ( error = ivas_td_binaural_renderer_ext( &ismInput->tdRendWrapper, ismInput->base.inConfig, NULL, ismInput->base.ctx.pCombinedOrientationData, &ismInput->currentPos, ismInput->hReverb, ism_md_subframe_update_ext,
...@@ -5421,7 +5638,7 @@ static ivas_error renderIsmToBinauralReverb( ...@@ -5421,7 +5638,7 @@ static ivas_error renderIsmToBinauralReverb(
push_wmops( "renderIsmToBinauralRoom" ); push_wmops( "renderIsmToBinauralRoom" );
/* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */ /* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */
ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000 / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) ); ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000.f / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) );
copyBufferTo2dArray( ismInput->base.inputBuffer, tmpRendBuffer ); copyBufferTo2dArray( ismInput->base.inputBuffer, tmpRendBuffer );
...@@ -5587,8 +5804,10 @@ static ivas_error renderIsmToSplitBinaural( ...@@ -5587,8 +5804,10 @@ static ivas_error renderIsmToSplitBinaural(
const MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData; const MULTI_BIN_REND_POSE_DATA *pMultiBinPoseData;
const SPLIT_REND_WRAPPER *pSplitRendWrapper; const SPLIT_REND_WRAPPER *pSplitRendWrapper;
IVAS_QUATERNION originalHeadRot[MAX_PARAM_SPATIAL_SUBFRAMES]; IVAS_QUATERNION originalHeadRot[MAX_PARAM_SPATIAL_SUBFRAMES];
int16_t i; int16_t i, ch, slot_idx, num_bands;
float tmpBinaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][L_FRAME48k]; float tmpBinaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][L_FRAME48k];
float tmpBinaural_CldfbRe[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX];
float tmpBinaural_CldfbIm[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX];
int16_t output_frame = ismInput->base.inputBuffer.config.numSamplesPerChannel; int16_t output_frame = ismInput->base.inputBuffer.config.numSamplesPerChannel;
COMBINED_ORIENTATION_HANDLE pCombinedOrientationData; COMBINED_ORIENTATION_HANDLE pCombinedOrientationData;
int16_t ism_md_subframe_update_ext; int16_t ism_md_subframe_update_ext;
...@@ -5599,7 +5818,7 @@ static ivas_error renderIsmToSplitBinaural( ...@@ -5599,7 +5818,7 @@ static ivas_error renderIsmToSplitBinaural(
pMultiBinPoseData = &pSplitRendWrapper->multiBinPoseData; pMultiBinPoseData = &pSplitRendWrapper->multiBinPoseData;
/* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */ /* Metadata Delay to sync with audio delay converted from ms to 5ms (1000/50/4) subframe index */
ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000 / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) ); ism_md_subframe_update_ext = (int16_t) roundf( ismInput->ism_metadata_delay_ms / ( 1000.f / FRAMES_PER_SEC / MAX_PARAM_SPATIAL_SUBFRAMES ) );
pCombinedOrientationData = *ismInput->base.ctx.pCombinedOrientationData; pCombinedOrientationData = *ismInput->base.ctx.pCombinedOrientationData;
...@@ -5655,10 +5874,29 @@ static ivas_error renderIsmToSplitBinaural( ...@@ -5655,10 +5874,29 @@ static ivas_error renderIsmToSplitBinaural(
return error; return error;
} }
if ( outAudio.config.is_cldfb )
{
/* Perform CLDFB analysis on rendered audio, since the output buffer is CLDFB domain */
num_bands = (int16_t) ( ( BINAURAL_MAXBANDS * *ismInput->base.ctx.pOutSampleRate ) / 48000 );
for ( ch = 0; ch < BINAURAL_CHANNELS; ch++ )
{
for ( slot_idx = 0; slot_idx < IVAS_CLDFB_NO_COL_MAX; slot_idx++ )
{
cldfbAnalysis_ts( &tmpProcessing[ch][num_bands * slot_idx],
&tmpBinaural_CldfbRe[BINAURAL_CHANNELS * pos_idx + ch][slot_idx][0],
&tmpBinaural_CldfbIm[BINAURAL_CHANNELS * pos_idx + ch][slot_idx][0],
num_bands,
ismInput->base.ctx.pSplitRendWrapper->hCldfbHandles->cldfbAna[pos_idx + ch] );
}
}
}
else
{
/* Copy rendered audio to tmp storage buffer. Copying directly to output would /* Copy rendered audio to tmp storage buffer. Copying directly to output would
* overwrite original audio, which is still needed for rendering next head pose. */ * overwrite original audio, which is still needed for rendering next head pose. */
mvr2r( tmpProcessing[0], tmpBinaural[2 * pos_idx], output_frame ); mvr2r( tmpProcessing[0], tmpBinaural[BINAURAL_CHANNELS * pos_idx], output_frame );
mvr2r( tmpProcessing[1], tmpBinaural[2 * pos_idx + 1], output_frame ); mvr2r( tmpProcessing[1], tmpBinaural[BINAURAL_CHANNELS * pos_idx + 1], output_frame );
}
/* Overwrite processing buffer with original input audio again */ /* Overwrite processing buffer with original input audio again */
copyBufferTo2dArray( ismInput->base.inputBuffer, tmpProcessing ); copyBufferTo2dArray( ismInput->base.inputBuffer, tmpProcessing );
...@@ -5670,7 +5908,14 @@ static ivas_error renderIsmToSplitBinaural( ...@@ -5670,7 +5908,14 @@ static ivas_error renderIsmToSplitBinaural(
pCombinedOrientationData->Quaternions[i] = originalHeadRot[i]; pCombinedOrientationData->Quaternions[i] = originalHeadRot[i];
} }
if ( outAudio.config.is_cldfb )
{
accumulateCLDFBArrayToBuffer( tmpBinaural_CldfbRe, tmpBinaural_CldfbIm, &outAudio );
}
else
{
accumulate2dArrayToBuffer( tmpBinaural, &outAudio ); accumulate2dArrayToBuffer( tmpBinaural, &outAudio );
}
pop_wmops(); pop_wmops();
/* Encoding to split rendering bitstream done at a higher level */ /* Encoding to split rendering bitstream done at a higher level */
...@@ -5705,11 +5950,13 @@ static ivas_error renderInputIsm( ...@@ -5705,11 +5950,13 @@ static ivas_error renderInputIsm(
{ {
ivas_error error; ivas_error error;
IVAS_REND_AudioBuffer inAudio; IVAS_REND_AudioBuffer inAudio;
int16_t cldfb2tdSampleFact;
error = IVAS_ERR_OK; error = IVAS_ERR_OK;
inAudio = ismInput->base.inputBuffer; inAudio = ismInput->base.inputBuffer;
if ( ismInput->base.numNewSamplesPerChannel != outAudio.config.numSamplesPerChannel ) cldfb2tdSampleFact = outAudio.config.is_cldfb ? 2 : 1;
if ( ismInput->base.numNewSamplesPerChannel * cldfb2tdSampleFact != outAudio.config.numSamplesPerChannel )
{ {
return IVAS_ERROR( IVAS_ERR_INVALID_BUFFER_SIZE, "Mismatch between the number of input samples vs number of requested output samples - currently not allowed" ); return IVAS_ERROR( IVAS_ERR_INVALID_BUFFER_SIZE, "Mismatch between the number of input samples vs number of requested output samples - currently not allowed" );
} }
...@@ -5834,8 +6081,7 @@ static ivas_error renderLfeToBinaural( ...@@ -5834,8 +6081,7 @@ static ivas_error renderLfeToBinaural(
num_cpy_smpl_prev_frame = mcInput->binauralDelaySmp; num_cpy_smpl_prev_frame = mcInput->binauralDelaySmp;
num_cpy_smpl_cur_frame = frame_size - num_cpy_smpl_prev_frame; num_cpy_smpl_cur_frame = frame_size - num_cpy_smpl_prev_frame;
/* Assuming LFE should be delayed by less that the duration of one frame */ assert( mcInput->binauralDelaySmp <= MAX_BIN_DELAY_SAMPLES );
assert( mcInput->binauralDelaySmp < frame_size );
/* Get delayed LFE signal from previous frame, apply gain and save in tmp buffer */ /* Get delayed LFE signal from previous frame, apply gain and save in tmp buffer */
v_multc( mcInput->lfeDelayBuffer, gain, tmpLfeBuffer, num_cpy_smpl_prev_frame ); v_multc( mcInput->lfeDelayBuffer, gain, tmpLfeBuffer, num_cpy_smpl_prev_frame );
...@@ -7414,14 +7660,12 @@ ivas_error IVAS_REND_SetIsmMetadataDelay( ...@@ -7414,14 +7660,12 @@ ivas_error IVAS_REND_SetIsmMetadataDelay(
static ivas_error getSamplesInternal( static ivas_error getSamplesInternal(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */ IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
IVAS_REND_AudioBuffer outAudio, /* i/o: buffer for output audio */ IVAS_REND_AudioBuffer outAudio /* i/o: buffer for output audio */
IVAS_REND_BitstreamBuffer *hBits /*i/o: buffer for input/output bitstream. Needed in split rendering mode*/
) )
{ {
ivas_error error; ivas_error error;
int16_t numOutChannels; int16_t numOutChannels;
int16_t cldfb2tdSampleFact; int16_t cldfb2tdSampleFact;
IVAS_REND_AudioBuffer outAudioOrig;
/* Validate function arguments */ /* Validate function arguments */
if ( hIvasRend == NULL || outAudio.data == NULL ) if ( hIvasRend == NULL || outAudio.data == NULL )
...@@ -7481,34 +7725,21 @@ static ivas_error getSamplesInternal( ...@@ -7481,34 +7725,21 @@ static ivas_error getSamplesInternal(
} }
} }
if ( ( error = IVAS_REND_NumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK ) if ( ( error = IVAS_REND_GetNumOutChannels( hIvasRend, &numOutChannels ) ) != IVAS_ERR_OK )
{ {
return error; return error;
} }
if ( numOutChannels != outAudio.config.numChannels && hIvasRend->outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && hIvasRend->outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) if ( numOutChannels != outAudio.config.numChannels &&
hIvasRend->outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED &&
hIvasRend->outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
{ {
return IVAS_ERR_WRONG_NUM_CHANNELS; return IVAS_ERR_WRONG_NUM_CHANNELS;
} }
/* Clear original output buffer */ /* Clear output buffer */
set_zero( outAudio.data, outAudio.config.numChannels * outAudio.config.numSamplesPerChannel ); set_zero( outAudio.data, outAudio.config.numChannels * outAudio.config.numSamplesPerChannel );
outAudioOrig = outAudio;
/* Use internal buffer if outputting split rendering bitstream */
if ( ( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED ) ||
( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) )
{
int16_t num_poses_orig;
num_poses_orig = hIvasRend->splitRendWrapper->multiBinPoseData.num_poses;
outAudio = hIvasRend->splitRendEncBuffer;
ISAR_PRE_REND_GetMultiBinPoseData( &hIvasRend->hRendererConfig->split_rend_config, &hIvasRend->splitRendWrapper->multiBinPoseData, hIvasRend->headRotData.sr_pose_pred_axis );
assert( num_poses_orig == hIvasRend->splitRendWrapper->multiBinPoseData.num_poses && "number of poses should not change dynamically" );
/* Clear output buffer for split rendering bitstream */
set_zero( outAudio.data, outAudio.config.numChannels * outAudio.config.numSamplesPerChannel );
}
if ( ( error = renderActiveInputsIsm( hIvasRend, outAudio ) ) != IVAS_ERR_OK ) if ( ( error = renderActiveInputsIsm( hIvasRend, outAudio ) ) != IVAS_ERR_OK )
{ {
return error; return error;
...@@ -7529,30 +7760,114 @@ static ivas_error getSamplesInternal( ...@@ -7529,30 +7760,114 @@ static ivas_error getSamplesInternal(
return error; return error;
} }
if ( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) return IVAS_ERR_OK;
}
/*-------------------------------------------------------------------*
* IVAS_REND_GetSamples()
*
*
*-------------------------------------------------------------------*/
ivas_error IVAS_REND_GetSamples(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
IVAS_REND_AudioBuffer outAudio /* i/o: buffer for output audio */
)
{ {
ISAR_SPLIT_REND_BITS_DATA bits; ivas_error error;
int16_t cldfb_in_flag;
float Cldfb_RealBuffer_Binaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX]; if ( ( error = getSamplesInternal( hIvasRend, outAudio ) ) != IVAS_ERR_OK )
float Cldfb_ImagBuffer_Binaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX]; {
return error;
}
if ( outAudio.config.is_cldfb == 0 )
{
#ifndef DISABLE_LIMITER
#ifdef DEBUGGING
hIvasRend->numClipping +=
#endif
limitRendererOutput( hIvasRend->hLimiter, outAudio.data, outAudio.config.numSamplesPerChannel, IVAS_LIMITER_THRESHOLD );
#endif
}
/* update global cominbed orientation start index */
ivas_combined_orientation_update_start_index( hIvasRend->hCombinedOrientationData, outAudio.config.numSamplesPerChannel );
return IVAS_ERR_OK;
}
/*-------------------------------------------------------------------*
* IVAS_REND_GetSplitBinauralBitstream()
*
*
*-------------------------------------------------------------------*/
ivas_error IVAS_REND_GetSplitBinauralBitstream(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
IVAS_REND_AudioBuffer outAudio, /* i/o: buffer for output audio */
IVAS_REND_BitstreamBuffer *hBits /* o : buffer for output bitstream */
)
{
ivas_error error;
int16_t ch; int16_t ch;
int16_t cldfb_in_flag;
int16_t i, ro_md_flag; int16_t i, ro_md_flag;
int16_t num_poses_orig;
float *tmpBinaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS], tmpBinaural_buff[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][L_FRAME48k]; float *tmpBinaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS], tmpBinaural_buff[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][L_FRAME48k];
float Cldfb_ImagBuffer_Binaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX];
float Cldfb_RealBuffer_Binaural[MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS][CLDFB_NO_COL_MAX][CLDFB_NO_CHANNELS_MAX];
IVAS_REND_AudioBufferConfig *pSplitEncBufConfig;
ISAR_SPLIT_REND_CONFIG_HANDLE pSplitRendConfig;
ISAR_SPLIT_REND_BITS_DATA bits;
for ( ch = 0; ch < MAX_OUTPUT_CHANNELS; ch++ ) for ( ch = 0; ch < MAX_HEAD_ROT_POSES * BINAURAL_CHANNELS; ch++ )
{ {
tmpBinaural[ch] = tmpBinaural_buff[ch]; tmpBinaural[ch] = tmpBinaural_buff[ch];
} }
if ( outAudio.config.is_cldfb == 1 ) cldfb_in_flag = getCldfbRendFlag( hIvasRend, IVAS_REND_AUDIO_CONFIG_TYPE_UNKNOWN );
pSplitEncBufConfig = &hIvasRend->splitRendEncBuffer.config;
pSplitRendConfig = &hIvasRend->hRendererConfig->split_rend_config;
/* 0 DoF / No pose correction retains frame size */
pSplitEncBufConfig->is_cldfb = cldfb_in_flag;
if ( pSplitRendConfig->dof == 0 || pSplitRendConfig->poseCorrectionMode == ISAR_SPLIT_REND_POSE_CORRECTION_MODE_NONE )
{
pSplitEncBufConfig->numSamplesPerChannel = outAudio.config.numSamplesPerChannel;
}
/* Pose correction requires 20ms */
else
{
pSplitEncBufConfig->numSamplesPerChannel = (int16_t) ( hIvasRend->sampleRateOut / FRAMES_PER_SEC );
}
pSplitEncBufConfig->numSamplesPerChannel *= cldfb_in_flag ? 2 : 1;
num_poses_orig = hIvasRend->splitRendWrapper->multiBinPoseData.num_poses;
ISAR_PRE_REND_GetMultiBinPoseData( pSplitRendConfig,
&hIvasRend->splitRendWrapper->multiBinPoseData,
hIvasRend->headRotData.sr_pose_pred_axis );
assert( num_poses_orig == hIvasRend->splitRendWrapper->multiBinPoseData.num_poses && "number of poses should not change dynamically" );
/* hIvasRend->splitRendEncBuffer contains multi-pose data for BINAURAL_SPLIT_CODED output
outAudio used later for main pose BINAURAL_SPLIT_PCM output */
if ( ( error = getSamplesInternal( hIvasRend, hIvasRend->splitRendEncBuffer ) ) != IVAS_ERR_OK )
{
return error;
}
/* copy outputs */
if ( hIvasRend->splitRendEncBuffer.config.is_cldfb == 1 )
{ {
cldfb_in_flag = 1; cldfb_in_flag = 1;
copyBufferToCLDFBarray( outAudio, Cldfb_RealBuffer_Binaural, Cldfb_ImagBuffer_Binaural ); copyBufferToCLDFBarray( hIvasRend->splitRendEncBuffer, Cldfb_RealBuffer_Binaural, Cldfb_ImagBuffer_Binaural );
} }
else else
{ {
cldfb_in_flag = 0; cldfb_in_flag = 0;
copyBufferTo2dArray( outAudio, tmpBinaural_buff ); copyBufferTo2dArray( hIvasRend->splitRendEncBuffer, tmpBinaural_buff );
} }
/* Encode split rendering bitstream */ /* Encode split rendering bitstream */
...@@ -7570,10 +7885,10 @@ static ivas_error getSamplesInternal( ...@@ -7570,10 +7885,10 @@ static ivas_error getSamplesInternal(
if ( ( error = ISAR_PRE_REND_MultiBinToSplitBinaural( hIvasRend->splitRendWrapper, if ( ( error = ISAR_PRE_REND_MultiBinToSplitBinaural( hIvasRend->splitRendWrapper,
hIvasRend->headRotData.headPositions[0], hIvasRend->headRotData.headPositions[0],
hIvasRend->hRendererConfig->split_rend_config.splitRendBitRate, pSplitRendConfig->splitRendBitRate,
hIvasRend->hRendererConfig->split_rend_config.codec, pSplitRendConfig->codec,
hIvasRend->hRendererConfig->split_rend_config.isar_frame_size_ms, pSplitRendConfig->isar_frame_size_ms,
hIvasRend->hRendererConfig->split_rend_config.codec_frame_size_ms, pSplitRendConfig->codec_frame_size_ms,
&bits, &bits,
Cldfb_RealBuffer_Binaural, Cldfb_RealBuffer_Binaural,
Cldfb_ImagBuffer_Binaural, Cldfb_ImagBuffer_Binaural,
...@@ -7589,14 +7904,13 @@ static ivas_error getSamplesInternal( ...@@ -7589,14 +7904,13 @@ static ivas_error getSamplesInternal(
convertInternalBitsBuffToBitsBuffer( hBits, bits ); convertInternalBitsBuffToBitsBuffer( hBits, bits );
/* reset to outAudioOrig in case of PCM output */ /* copy over first pose data to outAudio */
outAudio = outAudioOrig;
if ( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM ) if ( hIvasRend->outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
{ {
/* set outAudio to zero - getSamplesInternal only cleared splitRendEncBuffer */
set_zero( outAudio.data, outAudio.config.numChannels * outAudio.config.numSamplesPerChannel );
accumulate2dArrayToBuffer( tmpBinaural_buff, &outAudio ); accumulate2dArrayToBuffer( tmpBinaural_buff, &outAudio );
} }
}
if ( outAudio.config.is_cldfb == 0 ) if ( outAudio.config.is_cldfb == 0 )
{ {
...@@ -7615,54 +7929,6 @@ static ivas_error getSamplesInternal( ...@@ -7615,54 +7929,6 @@ static ivas_error getSamplesInternal(
} }
/*-------------------------------------------------------------------*
* IVAS_REND_GetSamples()
*
*
*-------------------------------------------------------------------*/
ivas_error IVAS_REND_GetSamples(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
IVAS_REND_AudioBuffer outAudio /* i/o: buffer for output audio */
)
{
return getSamplesInternal( hIvasRend, outAudio, NULL );
}
/*-------------------------------------------------------------------*
* IVAS_REND_GetSplitBinauralBitstream()
*
*
*-------------------------------------------------------------------*/
ivas_error IVAS_REND_GetSplitBinauralBitstream(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
IVAS_REND_AudioBuffer outAudio, /* i/o: buffer for output audio */
IVAS_REND_BitstreamBuffer *hBits /* o : buffer for output bitstream */
)
{
int16_t cldfb_in_flag;
cldfb_in_flag = getCldfbRendFlag( hIvasRend, IVAS_REND_AUDIO_CONFIG_TYPE_UNKNOWN );
hIvasRend->splitRendEncBuffer.config.is_cldfb = cldfb_in_flag;
if ( hIvasRend->hRendererConfig->split_rend_config.dof == 0 || hIvasRend->hRendererConfig->split_rend_config.poseCorrectionMode == ISAR_SPLIT_REND_POSE_CORRECTION_MODE_NONE )
{
hIvasRend->splitRendEncBuffer.config.numSamplesPerChannel = outAudio.config.numSamplesPerChannel;
}
else
{
hIvasRend->splitRendEncBuffer.config.numSamplesPerChannel = (int16_t) ( hIvasRend->sampleRateOut / FRAMES_PER_SEC );
}
hIvasRend->splitRendEncBuffer.config.numSamplesPerChannel *= cldfb_in_flag ? 2 : 1;
/* hIvasRend->splitRendEncBuffer used for BINAURAL_SPLIT_CODED output
outAudio used for BINAURAL_SPLIT_PCM output */
return getSamplesInternal( hIvasRend, outAudio, hBits );
}
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* IVAS_REND_GetSplitRendBitstreamHeader() * IVAS_REND_GetSplitRendBitstreamHeader()
* *
......
...@@ -134,7 +134,7 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout( ...@@ -134,7 +134,7 @@ ivas_error IVAS_REND_ConfigureCustomOutputLoudspeakerLayout(
/* Functions to be called before/during rendering */ /* Functions to be called before/during rendering */
ivas_error IVAS_REND_NumOutChannels( ivas_error IVAS_REND_GetNumOutChannels(
IVAS_REND_CONST_HANDLE hIvasRend, /* i : Renderer handle */ IVAS_REND_CONST_HANDLE hIvasRend, /* i : Renderer handle */
int16_t *numOutChannels /* o : number of output channels */ int16_t *numOutChannels /* o : number of output channels */
); );
...@@ -221,7 +221,8 @@ ivas_error IVAS_REND_GetHrtfStatisticsHandle( ...@@ -221,7 +221,8 @@ ivas_error IVAS_REND_GetHrtfStatisticsHandle(
ivas_error IVAS_REND_FeedInputAudio( ivas_error IVAS_REND_FeedInputAudio(
IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */ IVAS_REND_HANDLE hIvasRend, /* i/o: Renderer handle */
const IVAS_REND_InputId inputId, /* i : ID of the input */ const IVAS_REND_InputId inputId, /* i : ID of the input */
const IVAS_REND_ReadOnlyAudioBuffer inputAudio /* i : buffer with input audio */ const IVAS_REND_ReadOnlyAudioBuffer inputAudio, /* i : buffer with input audio */
const bool flushInputs /* i : flush input audio */
); );
ivas_error IVAS_REND_FeedInputObjectMetadata( ivas_error IVAS_REND_FeedInputObjectMetadata(
......
...@@ -305,7 +305,9 @@ MIME_ERROR MIME_Writer_Close( ...@@ -305,7 +305,9 @@ MIME_ERROR MIME_Writer_Close(
} }
static bool readByte( FILE *file, uint8_t *value ) static bool readByte(
FILE *file,
uint8_t *value )
{ {
if ( fread( value, 1, 1, file ) != 1U ) if ( fread( value, 1, 1, file ) != 1U )
{ {
...@@ -314,14 +316,13 @@ static bool readByte( FILE *file, uint8_t *value ) ...@@ -314,14 +316,13 @@ static bool readByte( FILE *file, uint8_t *value )
return true; return true;
} }
static bool readLong( FILE *file, uint16_t *value ) static bool readLong(
FILE *file,
uint16_t *value )
{ {
char buffer[4] = { 0 }; char buffer[4] = { 0 };
#ifdef CODE_IMPROVEMENTS
if ( fread( buffer, 1, 4, file ) != 1U ) if ( fread( buffer, 1, 4, file ) != 1U )
#else
if ( fread( buffer, 4, 1, file ) != 1U )
#endif
{ {
return false; return false;
} }
...@@ -346,7 +347,10 @@ static bool readLong( FILE *file, uint16_t *value ) ...@@ -346,7 +347,10 @@ static bool readLong( FILE *file, uint16_t *value )
* to the serial bitstream. * to the serial bitstream.
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
static void byteToSerialReordered( uint8_t byte, uint16_t *serial, const int16_t *sort_indices ) static void byteToSerialReordered(
uint8_t byte,
uint16_t *serial,
const int16_t *sort_indices )
{ {
for ( uint32_t i = 0; i < 8; ++i ) for ( uint32_t i = 0; i < 8; ++i )
{ {
...@@ -360,8 +364,11 @@ static void byteToSerialReordered( uint8_t byte, uint16_t *serial, const int16_t ...@@ -360,8 +364,11 @@ static void byteToSerialReordered( uint8_t byte, uint16_t *serial, const int16_t
byte <<= 1; byte <<= 1;
} }
return;
} }
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* byteToSerial() * byteToSerial()
* *
...@@ -369,18 +376,25 @@ static void byteToSerialReordered( uint8_t byte, uint16_t *serial, const int16_t ...@@ -369,18 +376,25 @@ static void byteToSerialReordered( uint8_t byte, uint16_t *serial, const int16_t
* to the given serial bitstream array. * to the given serial bitstream array.
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
static void byteToSerial( uint8_t byte, uint16_t *serial ) static void byteToSerial(
uint8_t byte,
uint16_t *serial )
{ {
const int16_t indices[8] = { 0, 1, 2, 3, 4, 5, 6, 7 }; const int16_t indices[8] = { 0, 1, 2, 3, 4, 5, 6, 7 };
byteToSerialReordered( byte, serial, indices ); byteToSerialReordered( byte, serial, indices );
return;
} }
static MIME_ERROR readHeader( MIME_HANDLE hMIME )
static MIME_ERROR readHeader(
MIME_HANDLE hMIME )
{ {
const char id[] = "#!EVS_MC1.0\n"; const char id[] = "#!EVS_MC1.0\n";
const uint16_t num_char_id = sizeof( id ) - 1; const uint16_t num_char_id = sizeof( id ) - 1;
char buffer[sizeof( id )] = { 0 }; char buffer[sizeof( id )] = { 0 };
if ( fread( buffer, sizeof( char ), num_char_id, hMIME->file ) != num_char_id ) if ( fread( buffer, sizeof( char ), num_char_id, hMIME->file ) != num_char_id )
{ {
return MIME_READ_ERROR; return MIME_READ_ERROR;
...@@ -398,13 +412,17 @@ static MIME_ERROR readHeader( MIME_HANDLE hMIME ) ...@@ -398,13 +412,17 @@ static MIME_ERROR readHeader( MIME_HANDLE hMIME )
return MIME_NO_ERROR; return MIME_NO_ERROR;
} }
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* MIME_Reader_Open_filename() * MIME_Reader_Open_filename()
* *
* Open MIME reader * Open MIME reader
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
MIME_ERROR MIME_Reader_Open_filename( MIME_HANDLE *phMIME, const char *filename ) MIME_ERROR MIME_Reader_Open_filename(
MIME_HANDLE *phMIME,
const char *filename )
{ {
MIME_ERROR error = MIME_NO_ERROR; MIME_ERROR error = MIME_NO_ERROR;
...@@ -440,7 +458,8 @@ MIME_ERROR MIME_Reader_Open_filename( MIME_HANDLE *phMIME, const char *filename ...@@ -440,7 +458,8 @@ MIME_ERROR MIME_Reader_Open_filename( MIME_HANDLE *phMIME, const char *filename
* Rewind currently opened file to beginning * Rewind currently opened file to beginning
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
MIME_ERROR MIME_Reader_Rewind( MIME_HANDLE hMIME ) MIME_ERROR MIME_Reader_Rewind(
MIME_HANDLE hMIME )
{ {
if ( !hMIME || !hMIME->file ) if ( !hMIME || !hMIME->file )
{ {
...@@ -455,7 +474,13 @@ MIME_ERROR MIME_Reader_Rewind( MIME_HANDLE hMIME ) ...@@ -455,7 +474,13 @@ MIME_ERROR MIME_Reader_Rewind( MIME_HANDLE hMIME )
return MIME_NO_ERROR; return MIME_NO_ERROR;
} }
static MIME_ERROR readEvsFrame( FILE *file, uint8_t ToC, uint16_t *serial, int16_t *num_bits, int16_t *bfi )
static MIME_ERROR readEvsFrame(
FILE *file,
uint8_t ToC,
uint16_t *serial,
int16_t *num_bits,
int16_t *bfi )
{ {
switch ( ToC & 0x0f ) switch ( ToC & 0x0f )
{ {
...@@ -524,7 +549,13 @@ static MIME_ERROR readEvsFrame( FILE *file, uint8_t ToC, uint16_t *serial, int16 ...@@ -524,7 +549,13 @@ static MIME_ERROR readEvsFrame( FILE *file, uint8_t ToC, uint16_t *serial, int16
return MIME_NO_ERROR; return MIME_NO_ERROR;
} }
static MIME_ERROR readAmrWbFrame( FILE *file, uint8_t ToC, uint16_t *serial, int16_t *num_bits, int16_t *bfi )
static MIME_ERROR readAmrWbFrame(
FILE *file,
uint8_t ToC,
uint16_t *serial,
int16_t *num_bits,
int16_t *bfi )
{ {
const uint8_t mode = ToC & 0x0f; const uint8_t mode = ToC & 0x0f;
...@@ -595,12 +626,18 @@ static MIME_ERROR readAmrWbFrame( FILE *file, uint8_t ToC, uint16_t *serial, int ...@@ -595,12 +626,18 @@ static MIME_ERROR readAmrWbFrame( FILE *file, uint8_t ToC, uint16_t *serial, int
return MIME_NO_ERROR; return MIME_NO_ERROR;
} }
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* MIME_ReadFrame_short() * MIME_ReadFrame_short()
* *
* Read MIME frame to serial bitstream * Read MIME frame to serial bitstream
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
MIME_ERROR MIME_ReadFrame_short( MIME_HANDLE hMIME, uint16_t *serial, int16_t *num_bits, int16_t *bfi )
MIME_ERROR MIME_ReadFrame_short(
MIME_HANDLE hMIME,
uint16_t *serial,
int16_t *num_bits,
int16_t *bfi )
{ {
if ( !hMIME ) if ( !hMIME )
{ {
...@@ -637,12 +674,16 @@ MIME_ERROR MIME_ReadFrame_short( MIME_HANDLE hMIME, uint16_t *serial, int16_t *n ...@@ -637,12 +674,16 @@ MIME_ERROR MIME_ReadFrame_short( MIME_HANDLE hMIME, uint16_t *serial, int16_t *n
return MIME_NO_ERROR; return MIME_NO_ERROR;
} }
/*-------------------------------------------------------------------* /*-------------------------------------------------------------------*
* MIME_Reader_Close() * MIME_Reader_Close()
* *
* Close MIME reader * Close MIME reader
*-------------------------------------------------------------------*/ *-------------------------------------------------------------------*/
MIME_ERROR MIME_Reader_Close( MIME_HANDLE *phMIME )
MIME_ERROR MIME_Reader_Close(
MIME_HANDLE *phMIME )
{ {
if ( phMIME == NULL || *phMIME == NULL ) if ( phMIME == NULL || *phMIME == NULL )
{ {
......
...@@ -80,11 +80,7 @@ static unsigned char *parseByte( unsigned char *buffer, unsigned char *value ) ...@@ -80,11 +80,7 @@ static unsigned char *parseByte( unsigned char *buffer, unsigned char *value )
static int readLong( FILE *file, unsigned int *value ) static int readLong( FILE *file, unsigned int *value )
{ {
char buffer[4] = { 0 }; char buffer[4] = { 0 };
#ifdef CODE_IMPROVEMENTS
if ( fread( buffer, 1, 4, file ) != 1U ) if ( fread( buffer, 1, 4, file ) != 1U )
#else
if ( fread( buffer, 4, 1, file ) != 1U )
#endif
{ {
return -1; return -1;
} }
......
...@@ -54,22 +54,14 @@ ...@@ -54,22 +54,14 @@
#define __TWI_SUCCESS ( 0 ) #define __TWI_SUCCESS ( 0 )
#define __TWI_ERROR ( -1 ) #define __TWI_ERROR ( -1 )
#ifdef CODE_IMPROVEMENTS
typedef struct tinyWaveInHandle typedef struct tinyWaveInHandle
#else
typedef struct __tinyWaveInHandle
#endif
{ {
FILE *theFile; FILE *theFile;
fpos_t dataChunkPos; fpos_t dataChunkPos;
uint32_t position; uint32_t position;
uint32_t length; uint32_t length;
uint32_t bps; uint32_t bps;
#ifdef CODE_IMPROVEMENTS
} tinyWaveInHandle, WAVEFILEIN; } tinyWaveInHandle, WAVEFILEIN;
#else
} __tinyWaveInHandle, WAVEFILEIN;
#endif
typedef struct typedef struct
{ {
......
...@@ -70,27 +70,15 @@ ...@@ -70,27 +70,15 @@
#endif #endif
#endif #endif
#ifdef CODE_IMPROVEMENTS
typedef struct tinyWaveOutHeader typedef struct tinyWaveOutHeader
#else
typedef struct __tinyWaveOutHeader
#endif
{ {
uint32_t riffType; /* 'RIFF' */ uint32_t riffType; /* 'RIFF' */
uint32_t riffSize; /* file size */ uint32_t riffSize; /* file size */
uint32_t waveType; /* 'WAVE' */ uint32_t waveType; /* 'WAVE' */
#ifdef CODE_IMPROVEMENTS
} tinyWaveOutHeader; } tinyWaveOutHeader;
#else
} __tinyWaveOutHeader;
#endif
#ifdef CODE_IMPROVEMENTS
typedef struct tinyWaveOutFmtChunk typedef struct tinyWaveOutFmtChunk
#else
typedef struct __tinyWaveOutFmtChunk
#endif
{ {
uint32_t formatType; uint32_t formatType;
uint32_t formatSize; uint32_t formatSize;
...@@ -103,31 +91,15 @@ typedef struct __tinyWaveOutFmtChunk ...@@ -103,31 +91,15 @@ typedef struct __tinyWaveOutFmtChunk
uint16_t bitsPerSample; uint16_t bitsPerSample;
/* wav fmt ext hdr here */ /* wav fmt ext hdr here */
#ifdef CODE_IMPROVEMENTS
} tinyWaveOutFmtChunk; } tinyWaveOutFmtChunk;
#else
} __tinyWaveOutFmtChunk;
#endif
#ifdef CODE_IMPROVEMENTS
typedef struct tinyWaveOutDataChunk
#else
typedef struct tinyWaveOutDataChunk typedef struct tinyWaveOutDataChunk
#endif
{ {
uint32_t dataType; uint32_t dataType;
uint32_t dataSize; uint32_t dataSize;
#ifdef CODE_IMPROVEMENTS
} tinyWaveOutDataChunk; } tinyWaveOutDataChunk;
#else
} __tinyWaveOutDataChunk;
#endif
#ifdef CODE_IMPROVEMENTS
typedef struct tinyWaveOutHandle typedef struct tinyWaveOutHandle
#else
typedef struct __tinyWaveOutHandle
#endif
{ {
FILE *theFile; FILE *theFile;
uint32_t dataSize; uint32_t dataSize;
...@@ -136,11 +108,7 @@ typedef struct __tinyWaveOutHandle ...@@ -136,11 +108,7 @@ typedef struct __tinyWaveOutHandle
uint32_t dataChunkOffset; uint32_t dataChunkOffset;
uint32_t bps; uint32_t bps;
uint32_t clipCount; uint32_t clipCount;
#ifdef CODE_IMPROVEMENTS
} tinyWaveOutHandle, WAVEFILEOUT; } tinyWaveOutHandle, WAVEFILEOUT;
#else
} __tinyWaveOutHandle, WAVEFILEOUT;
#endif
/*--- local protos --------------------------------------------------*/ /*--- local protos --------------------------------------------------*/
static __inline uint32_t BigEndian32( char, char, char, char ); static __inline uint32_t BigEndian32( char, char, char, char );
...@@ -163,15 +131,9 @@ static WAVEFILEOUT *CreateBWF( ...@@ -163,15 +131,9 @@ static WAVEFILEOUT *CreateBWF(
/* ,const uint32_t writeWaveExt */ ) /* ,const uint32_t writeWaveExt */ )
{ {
WAVEFILEOUT *self; WAVEFILEOUT *self;
#ifdef CODE_IMPROVEMENTS
tinyWaveOutHeader whdr; tinyWaveOutHeader whdr;
tinyWaveOutFmtChunk wfch; tinyWaveOutFmtChunk wfch;
tinyWaveOutDataChunk wdch; tinyWaveOutDataChunk wdch;
#else
__tinyWaveOutHeader whdr;
__tinyWaveOutFmtChunk wfch;
__tinyWaveOutDataChunk wdch;
#endif
uint32_t blockAlignment = 0; uint32_t blockAlignment = 0;
uint32_t ByteCnt = 0; /* Byte counter for fwrite */ uint32_t ByteCnt = 0; /* Byte counter for fwrite */
......
...@@ -278,7 +278,8 @@ Options: ...@@ -278,7 +278,8 @@ Options:
The decoder may read rtpdump files containing TS26.445 Annex A.2.2 The decoder may read rtpdump files containing TS26.445 Annex A.2.2
EVS RTP Payload Format. The SDP parameter hf_only is required. EVS RTP Payload Format. The SDP parameter hf_only is required.
Reading RFC4867 AMR/AMR-WB RTP payload format is not supported. Reading RFC4867 AMR/AMR-WB RTP payload format is not supported.
-Tracefile TF : VoIP mode: Generate trace file named TF -Tracefile TF : VoIP mode: Generate trace file named TF. Requires -no_delay_cmp to
be enabled so that trace contents remain in sync with audio output.
-fec_cfg_file : Optimal channel aware configuration computed by the JBM -fec_cfg_file : Optimal channel aware configuration computed by the JBM
as described in Section 6.3.1 of TS26.448. The output is as described in Section 6.3.1 of TS26.448. The output is
written into a .txt file. Each line contains the FER indicator written into a .txt file. Each line contains the FER indicator
......
...@@ -781,6 +781,10 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1 ...@@ -781,6 +781,10 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1
../IVAS_cod -sba 3 128000 32 testv/stv3OA32c.wav bit ../IVAS_cod -sba 3 128000 32 testv/stv3OA32c.wav bit
../IVAS_dec -t testv/headrot.csv -exof testv/headrot_case00_3000_q_combinedRotationTest.csv -otr avg BINAURAL_ROOM_IR 32 bit testv/stv3OA32c.pcm_SBA_128000_32-32_Binaural_room_Headrot_EXOF_OtrAvg.tst ../IVAS_dec -t testv/headrot.csv -exof testv/headrot_case00_3000_q_combinedRotationTest.csv -otr avg BINAURAL_ROOM_IR 32 bit testv/stv3OA32c.pcm_SBA_128000_32-32_Binaural_room_Headrot_EXOF_OtrAvg.tst
// SBA at 128 kbps, 48kHz in, 48kHz out, HOA3 out, mono detector test
../IVAS_cod -sba 3 128000 48 testv/stv3OA48c_mono.wav bit
../IVAS_dec HOA3 48 bit testv/stv3OA48c_mono.pcm_SBA_128000_48-48_HOA3.tst
// SBA at 192 kbps, 48kHz in, 48kHz out, HOA2 out, random FER at 5% // SBA at 192 kbps, 48kHz in, 48kHz out, HOA2 out, random FER at 5%
../IVAS_cod -sba 3 192000 48 testv/stv3OA48c.wav bit ../IVAS_cod -sba 3 192000 48 testv/stv3OA48c.wav bit
eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g192 bit_error eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g192 bit_error
...@@ -1582,143 +1586,143 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1 ...@@ -1582,143 +1586,143 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1
// stereo at 32 kbps, 48 kHz in, 32 kHz out, DTX on, JBM Prof 0 // stereo at 32 kbps, 48 kHz in, 32 kHz out, DTX on, JBM Prof 0
../IVAS_cod -stereo -dtx 32000 48 testv/stvST48n.wav bit ../IVAS_cod -stereo -dtx 32000 48 testv/stvST48n.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP STEREO 32 netsimoutput testv/stvST48n.wav_stereo_32000_48-32_DTX_JBM0.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP STEREO 32 netsimoutput testv/stvST48n.wav_stereo_32000_48-32_DTX_JBM0.tst
// 4 ISm with metadata at 64 kbps, 48 kHz in, 48 kHz out, DTX on, EXT out, JBM Prof 0 // 4 ISm with metadata at 64 kbps, 48 kHz in, 48 kHz out, DTX on, EXT out, JBM Prof 0
../IVAS_cod -dtx -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv 64000 48 testv/stv4ISM48n.wav bit ../IVAS_cod -dtx -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv 64000 48 testv/stv4ISM48n.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stv4ISM48s.wav_64000_48-48_DTX_EXT_JBM0.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stv4ISM48s.wav_64000_48-48_DTX_EXT_JBM0.tst
// MASA 1dir 1TC at 13.2 kbps, 48kHz in, 32kHz out, DTX on, EXT out, JBM Prof 0 // MASA 1dir 1TC at 13.2 kbps, 48kHz in, 32kHz out, DTX on, EXT out, JBM Prof 0
../IVAS_cod -dtx -masa 1 testv/stv1MASA1TC48n.met 13200 48 testv/stv1MASA1TC48n.wav bit ../IVAS_cod -dtx -masa 1 testv/stv1MASA1TC48n.met 13200 48 testv/stv1MASA1TC48n.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP EXT 32 netsimoutput testv/stv1MASA1TC48n.wav_13200_48-32_DTX_EXT_JBM0.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP EXT 32 netsimoutput testv/stv1MASA1TC48n.wav_13200_48-32_DTX_EXT_JBM0.tst
// SBA at 24.4 kbps, 32kHz in, 32kHz out, DTX on, BINAURAL out, JBM 0 // SBA at 24.4 kbps, 32kHz in, 32kHz out, DTX on, BINAURAL out, JBM 0
../IVAS_cod -sba 3 -dtx 24400 32 testv/stv3OA32c.wav bit ../IVAS_cod -sba 3 -dtx 24400 32 testv/stv3OA32c.wav bit
networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0 networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_0.dat bit netsimoutput tracefile_sim 2 0
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL 32 netsimoutput testv/stv3OA32c.wav_SBA_24400_32-32_DTX_Binaural_JBM0.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 32 netsimoutput testv/stv3OA32c.wav_SBA_24400_32-32_DTX_Binaural_JBM0.tst
// stereo at 48 kbps, 16 kHz in, 16 kHz out, DTX on, JBM Prof 5 // stereo at 48 kbps, 16 kHz in, 16 kHz out, DTX on, JBM Prof 5
../IVAS_cod -stereo -dtx 48000 16 testv/stvST16n.wav bit ../IVAS_cod -stereo -dtx 48000 16 testv/stvST16n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP STEREO 16 netsimoutput testv/stvST16n.wav_stereo_48000_16-16_DTX_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP STEREO 16 netsimoutput testv/stvST16n.wav_stereo_48000_16-16_DTX_JBM5.tst
// 4 ISm with metadata at 32 kbps, 48 kHz in, 48 kHz out, FOA out, JBM Prof 5 // 4 ISm with metadata at 32 kbps, 48 kHz in, 48 kHz out, FOA out, JBM Prof 5
../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv 32000 48 testv/stv4ISM48s.wav bit ../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv 32000 48 testv/stv4ISM48s.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
../IVAS_dec -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv4ISM48s.wav_32000_48-48_FOA_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv4ISM48s.wav_32000_48-48_FOA_JBM5.tst
// 3 ISM with metadata bitrate switching from 48 kbps to 32 kbps, 48 kHz in, 32 kHz out, DTX, BINAURAL_ROOM_IR out, JBM Prof 5 // 3 ISM with metadata bitrate switching from 48 kbps to 32 kbps, 48 kHz in, 32 kHz out, DTX, BINAURAL_ROOM_IR out, JBM Prof 5
../IVAS_cod -dtx -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv ../scripts/switchPaths/sw_48-32k_10fr.bin 48 testv/stv3ISM48s.wav bit ../IVAS_cod -dtx -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv ../scripts/switchPaths/sw_48-32k_10fr.bin 48 testv/stv3ISM48s.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_IR 32 netsimoutput testv/stv3ISM48s.wav_sw_48-32_DTX_BINAURAL_ROOM_IR_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_IR 32 netsimoutput testv/stv3ISM48s.wav_sw_48-32_DTX_BINAURAL_ROOM_IR_JBM5.tst
// SBA at 80 kbps, 32kHz in, 32kHz out, HOA3 out, JBM Prof 5 // SBA at 80 kbps, 32kHz in, 32kHz out, HOA3 out, JBM Prof 5
../IVAS_cod -sba 3 80000 32 testv/stv3OA32c.wav bit ../IVAS_cod -sba 3 80000 32 testv/stv3OA32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP HOA3 32 netsimoutput testv/stv3OA32c.wav_SBA_80000_32-32_HOA3_JBM5.tst ../IVAS_dec -no_delay_cmp -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 // SBA at 13.2 kbps, 48kHz in, 48kHz out, BINAURAL out, JBM Prof 5
../IVAS_cod -sba 1 13200 48 testv/stvFOA48c.wav bit ../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 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 ../IVAS_dec -no_delay_cmp -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
../IVAS_dec -Tracefile tracefile_dec -VOIP 7_1_4 48 netsimoutput testv/stv51MC48c.wav_MC51_384000_48-48_7_1_4_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 7_1_4 48 netsimoutput testv/stv51MC48c.wav_MC51_384000_48-48_7_1_4_JBM5.tst
// Multi-channel 7_1_4 at 256 kbps, 48kHz in, 48kHz out, 7_1_4 out, JBM Prof 5 // Multi-channel 7_1_4 at 256 kbps, 48kHz in, 48kHz out, 7_1_4 out, JBM Prof 5
../IVAS_cod -mc 7_1_4 256000 48 testv/stv714MC48c.wav bit ../IVAS_cod -mc 7_1_4 256000 48 testv/stv714MC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 7_1_4 48 netsimoutput testv/stv714MC48c.wav_MC714_256000_48-48_7_1_4_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 7_1_4 48 netsimoutput testv/stv714MC48c.wav_MC714_256000_48-48_7_1_4_JBM5.tst
// Multi-channel 7_1 bitrate switching, 48kHz in, 32kHz out, BINAURAL_ROOM_REVERB out, HR, JBM Prof 5 // Multi-channel 7_1 bitrate switching, 48kHz in, 32kHz out, BINAURAL_ROOM_REVERB out, HR, JBM Prof 5
../IVAS_cod -mc 7_1 ../scripts/switchPaths/sw_24k4_384k.bin 48 testv/stv71MC48c.wav bit ../IVAS_cod -mc 7_1 ../scripts/switchPaths/sw_24k4_384k.bin 48 testv/stv71MC48c.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
../IVAS_dec -T testv/headrot.csv -Tracefile tracefile_dec -VOIP binaural_room_reverb 32 netsimoutput testv/stv71MC48c.wav_MC71_brsw_48-32_BinauralRoomReverb_Headrot_JBM5.tst ../IVAS_dec -T testv/headrot.csv -no_delay_cmp -Tracefile tracefile_dec -VOIP binaural_room_reverb 32 netsimoutput testv/stv71MC48c.wav_MC71_brsw_48-32_BinauralRoomReverb_Headrot_JBM5.tst
// Multi-channel 7_1_4 bitrate switching, 48kHz in, 48kHz out, BINAURAL out, HR, JBM Prof 5 // Multi-channel 7_1_4 bitrate switching, 48kHz in, 48kHz out, BINAURAL out, HR, JBM Prof 5
../IVAS_cod -mc 7_1_4 ../scripts/switchPaths/sw_24k4_384k.bin 48 testv/stv714MC48c.wav bit ../IVAS_cod -mc 7_1_4 ../scripts/switchPaths/sw_24k4_384k.bin 48 testv/stv714MC48c.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
../IVAS_dec -T testv/headrot.csv -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stv714MC48c.wav_MC714_brsw_48-48_BINAURAL_Headrot_JBM5.tst ../IVAS_dec -T testv/headrot.csv -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stv714MC48c.wav_MC714_brsw_48-48_BINAURAL_Headrot_JBM5.tst
// MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 32kHz out, 5_1 out, JBM Prof 5 // MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 32kHz out, 5_1 out, JBM Prof 5
../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.wav bit ../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 5_1 32 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-32_5_1_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 5_1 32 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-32_5_1_JBM5.tst
// MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 48kHz out, STEREO out, JBM Prof 5 // MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 48kHz out, STEREO out, JBM Prof 5
../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.wav bit ../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP STEREO 48 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-48_STEREO_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP STEREO 48 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-48_STEREO_JBM5.tst
// MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 48kHz out, FOA out, JBM Prof 5 // MASA 1dir 1TC bitrate switching from 13.2 kbps to 128 kbps, 48kHz in, 48kHz out, FOA out, JBM Prof 5
../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.wav bit ../IVAS_cod -masa 1 testv/stv1MASA1TC48n.met ../scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 testv/stv1MASA1TC48n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-48_FOA_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv1MASA1TC48n.wav_sw_48-48_FOA_JBM5.tst
// MASA 1dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 16kHz out, BINAURAL out, JBM Prof 5 // MASA 1dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 16kHz out, BINAURAL out, JBM Prof 5
../IVAS_cod -masa 2 testv/stv1MASA2TC48n.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv1MASA2TC48n.wav bit ../IVAS_cod -masa 2 testv/stv1MASA2TC48n.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv1MASA2TC48n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL 16 netsimoutput testv/stv1MASA2TC48n.wav_sw_48-16_BINAURAL_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 16 netsimoutput testv/stv1MASA2TC48n.wav_sw_48-16_BINAURAL_JBM5.tst
// MASA 1dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 32kHz out, MONO out, JBM Prof 5 // MASA 1dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 32kHz out, MONO out, JBM Prof 5
../IVAS_cod -masa 2 testv/stv1MASA2TC48n.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv1MASA2TC48n.wav bit ../IVAS_cod -masa 2 testv/stv1MASA2TC48n.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv1MASA2TC48n.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
../IVAS_dec -Tracefile tracefile_dec -VOIP MONO 32 netsimoutput testv/stv1MASA2TC48n.wav_sw_48-32_MONO_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP MONO 32 netsimoutput testv/stv1MASA2TC48n.wav_sw_48-32_MONO_JBM5.tst
// MASA 2dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 48kHz out, EXT out, JBM Prof 5 // MASA 2dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 48kHz out, EXT out, JBM Prof 5
../IVAS_cod -masa 2 testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv2MASA2TC48c.wav bit ../IVAS_cod -masa 2 testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stv2MASA2TC48c.wav_sw_48-48_EXT_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stv2MASA2TC48c.wav_sw_48-48_EXT_JBM5.tst
// MASA 2dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 16kHz out, BINAURAL out, JBM Prof 5 // MASA 2dir 2TC bitrate switching from 13.2 kbps to 512 kbps, 48kHz in, 16kHz out, BINAURAL out, JBM Prof 5
../IVAS_cod -masa 2 testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv2MASA2TC48c.wav bit ../IVAS_cod -masa 2 testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stv2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL 16 netsimoutput testv/stv2MASA2TC48c.wav_sw_48-16_BINAURAL_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 16 netsimoutput testv/stv2MASA2TC48c.wav_sw_48-16_BINAURAL_JBM5.tst
// OMASA 2Dir2TC 1ISM at br sw techs 13.2 to 512 kbps start 24.4 kbps, 48kHz in, 48kHz out, BINAURAL_ROOM_IR out, JBM Prof 5 // OMASA 2Dir2TC 1ISM at br sw techs 13.2 to 512 kbps start 24.4 kbps, 48kHz in, 48kHz out, BINAURAL_ROOM_IR out, JBM Prof 5
../IVAS_cod -ism_masa 1 2 testv/stvISM1.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_24k4_omasatechs_1ism.bin 48 testv/stvOMASA_1ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 1 2 testv/stvISM1.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_24k4_omasatechs_1ism.bin 48 testv/stvOMASA_1ISM_2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_IR 48 netsimoutput testv/stvOMASA_1ISM_2MASA2TC48c.wav_BINAURAL_ROOM_IR_sw_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_IR 48 netsimoutput testv/stvOMASA_1ISM_2MASA2TC48c.wav_BINAURAL_ROOM_IR_sw_48-48_JBM5.tst
// OMASA 2Dir2TC 2ISM at br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 48kHz out, 7.1 out, JBM Prof 5 // OMASA 2Dir2TC 2ISM at br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 48kHz out, 7.1 out, JBM Prof 5
../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv NULL testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_2ism.bin 48 testv/stvOMASA_2ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv NULL testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_2ism.bin 48 testv/stvOMASA_2ISM_2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 7_1 48 netsimoutput testv/stvOMASA_2ISM_2MASA2TC48c.wav_7_1_sw_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 7_1 48 netsimoutput testv/stvOMASA_2ISM_2MASA2TC48c.wav_7_1_sw_48-48_JBM5.tst
// OMASA 2Dir2TC 3ISM at br sw techs 13.2 to 512 kbps start 160 kbps, 48kHz in, 48kHz out, MONO out, JBM Prof 5 // OMASA 2Dir2TC 3ISM at br sw techs 13.2 to 512 kbps start 160 kbps, 48kHz in, 48kHz out, MONO out, JBM Prof 5
../IVAS_cod -ism_masa 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_160k_omasatechs_3ism.bin 48 testv/stvOMASA_3ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_160k_omasatechs_3ism.bin 48 testv/stvOMASA_3ISM_2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP MONO 48 netsimoutput testv/stvOMASA_3ISM_2MASA2TC48c.wav_MONO_sw_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP MONO 48 netsimoutput testv/stvOMASA_3ISM_2MASA2TC48c.wav_MONO_sw_48-48_JBM5.tst
// OMASA 2Dir1TC 3ISM at br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 32kHz out, STEREO out, JBM Prof 5 // OMASA 2Dir1TC 3ISM at br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 32kHz out, STEREO out, JBM Prof 5
../IVAS_cod -ism_masa 3 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv2MASA1TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_3ism.bin 48 testv/stvOMASA_3ISM_2MASA1TC48c.wav bit ../IVAS_cod -ism_masa 3 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv2MASA1TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_3ism.bin 48 testv/stvOMASA_3ISM_2MASA1TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP STEREO 32 netsimoutput testv/stvOMASA_3ISM_2MASA1TC48c.wav_STEREO_sw_48-32_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP STEREO 32 netsimoutput testv/stvOMASA_3ISM_2MASA1TC48c.wav_STEREO_sw_48-32_JBM5.tst
// OMASA 1Dir2TC 3ISM at br sw techs 13.2 to 512 kbps start 24.4 kbps, 32kHz in, 48kHz out, 5.1.2 out, JBM Prof 5 // OMASA 1Dir2TC 3ISM at br sw techs 13.2 to 512 kbps start 24.4 kbps, 32kHz in, 48kHz out, 5.1.2 out, JBM Prof 5
../IVAS_cod -ism_masa 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv1MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_24k4_omasatechs_3ism.bin 32 testv/stvOMASA_3ISM_1MASA2TC32c.wav bit ../IVAS_cod -ism_masa 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stv1MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_24k4_omasatechs_3ism.bin 32 testv/stvOMASA_3ISM_1MASA2TC32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 5_1_2 48 netsimoutput testv/stvOMASA_3ISM_1MASA2TC32c.wav_5_1_2_sw_32-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 5_1_2 48 netsimoutput testv/stvOMASA_3ISM_1MASA2TC32c.wav_5_1_2_sw_32-48_JBM5.tst
// OMASA 1Dir1TC 4ISM at br sw techs 13.2 to 512 kbps start 32 kbps, 48kHz in, 48kHz out, BINAURAL out, JBM Prof 5 // OMASA 1Dir1TC 4ISM at br sw techs 13.2 to 512 kbps start 32 kbps, 48kHz in, 48kHz out, BINAURAL out, JBM Prof 5
../IVAS_cod -ism_masa 4 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA1TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_32k_omasatechs_4ism.bin 48 testv/stvOMASA_4ISM_1MASA1TC48c.wav bit ../IVAS_cod -ism_masa 4 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA1TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_32k_omasatechs_4ism.bin 48 testv/stvOMASA_4ISM_1MASA1TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stvOMASA_4ISM_1MASA1TC48c.wav_BINAURAL_sw_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stvOMASA_4ISM_1MASA1TC48c.wav_BINAURAL_sw_48-48_JBM5.tst
// OMASA 1Dir2TC 4ISM at br sw techs 13.2 to 512 kbps start 80 kbps, 48kHz in, 48kHz out, FOA out, JBM Prof 5 // OMASA 1Dir2TC 4ISM at br sw techs 13.2 to 512 kbps start 80 kbps, 48kHz in, 48kHz out, FOA out, JBM Prof 5
../IVAS_cod -ism_masa 4 2 NULL testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_80k_omasatechs_4ism.bin 48 testv/stvOMASA_4ISM_1MASA2TC48c.wav bit ../IVAS_cod -ism_masa 4 2 NULL testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_80k_omasatechs_4ism.bin 48 testv/stvOMASA_4ISM_1MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOMASA_4ISM_1MASA2TC48c.wav_FOA_sw_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOMASA_4ISM_1MASA2TC48c.wav_FOA_sw_48-48_JBM5.tst
// OMASA 2Dir2TC 4ISM at 256 kbps, 48kHz in, 48kHz out, EXT out, JBM Prof 5 // OMASA 2Dir2TC 4ISM at 256 kbps, 48kHz in, 48kHz out, EXT out, JBM Prof 5
../IVAS_cod -ism_masa 4 2 testv/stvISM1.csv testv/stvISM2.csv NULL testv/stvISM4.csv testv/stv2MASA2TC48c.met 256000 48 testv/stvOMASA_4ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 4 2 testv/stvISM1.csv testv/stvISM2.csv NULL testv/stvISM4.csv testv/stv2MASA2TC48c.met 256000 48 testv/stvOMASA_4ISM_2MASA2TC48c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stvOMASA_4ISM_2MASA2TC48c.wav_EXT_256000_48-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP EXT 48 netsimoutput testv/stvOMASA_4ISM_2MASA2TC48c.wav_EXT_256000_48-48_JBM5.tst
// OMASA 1Dir1TC 4ISM 48 kbps 48kHz in, 48kHz out, BINAURAL_ROOM_REVERB out custom configuration // OMASA 1Dir1TC 4ISM 48 kbps 48kHz in, 48kHz out, BINAURAL_ROOM_REVERB out custom configuration
../IVAS_cod -ism_masa 4 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA1TC48c.met 48000 48 testv/stvOMASA_4ISM_1MASA1TC48c.wav bit ../IVAS_cod -ism_masa 4 1 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv1MASA1TC48c.met 48000 48 testv/stvOMASA_4ISM_1MASA1TC48c.wav bit
...@@ -1993,7 +1997,7 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_10pct.g ...@@ -1993,7 +1997,7 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_10pct.g
// OSBA 2OA 2ISM bitrate switching, 32kHz in, 48kHz out, BINAURAL_ROOM_REVERB out, JBM Prof 5 // OSBA 2OA 2ISM bitrate switching, 32kHz in, 48kHz out, BINAURAL_ROOM_REVERB out, JBM Prof 5
../IVAS_cod -ism_sba 2 2 testv/stvISM1.csv testv/stvISM2.csv ../scripts/switchPaths/sw_24k4_256k.bin 32 testv/stvOSBA_2ISM_2OA32c.wav bit ../IVAS_cod -ism_sba 2 2 testv/stvISM1.csv testv/stvISM2.csv ../scripts/switchPaths/sw_24k4_256k.bin 32 testv/stvOSBA_2ISM_2OA32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_REVERB 48 netsimoutput testv/stvOSBA_2ISM_2OA32c.wav_BINAURAL_brsw_32-48_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL_ROOM_REVERB 48 netsimoutput testv/stvOSBA_2ISM_2OA32c.wav_BINAURAL_brsw_32-48_JBM5.tst
// OMASA 2Dir2TC 4ISM at 80 kbps, 48kHz in, 48kHz out, BINAURAL out, default object editing, 1SEP-PARAM // OMASA 2Dir2TC 4ISM at 80 kbps, 48kHz in, 48kHz out, BINAURAL out, default object editing, 1SEP-PARAM
...@@ -2003,12 +2007,12 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit ...@@ -2003,12 +2007,12 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit
// OMASA 2Dir2TC 4ISM at 256 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing, JBM Prof 5, DISC // OMASA 2Dir2TC 4ISM at 256 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing, JBM Prof 5, DISC
../IVAS_cod -ism_masa 4 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv2MASA2TC48c.met 256000 48 testv/stvOMASA_4ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 4 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv testv/stv2MASA2TC48c.met 256000 48 testv/stvOMASA_4ISM_2MASA2TC48c.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
../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stvOMASA_4ISM_2MASA2TC48c.wav_BINAURAL_256000_48-48_OE_JBM5.tst ../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stvOMASA_4ISM_2MASA2TC48c.wav_BINAURAL_256000_48-48_OE_JBM5.tst
// OMASA 2Dir2TC 2ISM at 96 kbps, 48kHz in, 48kHz out, FOA out, object editing, JBM Prof 5, DISC // OMASA 2Dir2TC 2ISM at 96 kbps, 48kHz in, 48kHz out, FOA out, object editing, JBM Prof 5, DISC
../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv testv/stvISM2.csv testv/stv2MASA2TC48c.met 96000 48 testv/stvOMASA_2ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv testv/stvISM2.csv testv/stv2MASA2TC48c.met 96000 48 testv/stvOMASA_2ISM_2MASA2TC48c.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
../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOMASA_2ISM_2MASA2TC48c.wav_FOA_96000_48-48_OE_JBM5.tst ../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOMASA_2ISM_2MASA2TC48c.wav_FOA_96000_48-48_OE_JBM5.tst
// OMASA 2Dir2TC 2ISM br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing // OMASA 2Dir2TC 2ISM br sw techs 13.2 to 512 kbps start 48 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing
../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv testv/stvISM2.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_2ism.bin 48 testv/stvOMASA_2ISM_2MASA2TC48c.wav bit ../IVAS_cod -ism_masa 2 2 testv/stvISM1.csv testv/stvISM2.csv testv/stv2MASA2TC48c.met ../scripts/switchPaths/sw_13k2_512k_2fr_start_48k_omasatechs_2ism.bin 48 testv/stvOMASA_2ISM_2MASA2TC48c.wav bit
...@@ -2021,7 +2025,7 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit ...@@ -2021,7 +2025,7 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit
// OSBA 2OA 3ISM at 128 kbps, 48kHz in, 48kHz out, FOA out, object editing, JBM Prof 5, DISC // OSBA 2OA 3ISM at 128 kbps, 48kHz in, 48kHz out, FOA out, object editing, JBM Prof 5, DISC
../IVAS_cod -ism_sba 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 128000 48 testv/stvOSBA_3ISM_2OA48c.wav bit ../IVAS_cod -ism_sba 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 128000 48 testv/stvOSBA_3ISM_2OA48c.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
../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOSBA_3ISM_2OA48c.wav_FOA_128000_48-48_OE_JBM5.tst ../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stvOSBA_3ISM_2OA48c.wav_FOA_128000_48-48_OE_JBM5.tst
// OSBA 2OA 3ISM at bitrate switching 13.2 to 512 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing // OSBA 2OA 3ISM at bitrate switching 13.2 to 512 kbps, 48kHz in, 48kHz out, BINAURAL out, object editing
../IVAS_cod -ism_sba 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stvOSBA_3ISM_2OA48c.wav bit ../IVAS_cod -ism_sba 3 2 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv ../scripts/switchPaths/sw_13k2_512k.bin 48 testv/stvOSBA_3ISM_2OA48c.wav bit
...@@ -2039,12 +2043,12 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1 ...@@ -2039,12 +2043,12 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1
// 3 ISM with metadata at 24.4 kbps, 48 kHz in, 48 kHz out, FOA out, object editing, JBM Prof 5, PARAM_ISM // 3 ISM with metadata at 24.4 kbps, 48 kHz in, 48 kHz out, FOA out, object editing, JBM Prof 5, PARAM_ISM
../IVAS_cod -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 24400 48 testv/stv3ISM48s.wav bit ../IVAS_cod -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 24400 48 testv/stv3ISM48s.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
../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv3ISM48s.wav_24400_48-48_FOA_OE_JBM5.tst ../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv3ISM48s.wav_24400_48-48_FOA_OE_JBM5.tst
// 3 ISM with metadata at 384 kbps, 48 kHz in, 48 kHz out, FOA out, object editing, JBM Prof 5, DISC // 3 ISM with metadata at 384 kbps, 48 kHz in, 48 kHz out, FOA out, object editing, JBM Prof 5, DISC
../IVAS_cod -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 384000 48 testv/stv3ISM48s.wav bit ../IVAS_cod -ism 3 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv 384000 48 testv/stv3ISM48s.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
../IVAS_dec -obj_edit NULL -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv3ISM48s.wav_384000_48-48_FOA_OE_JBM5.tst ../IVAS_dec -obj_edit NULL -no_delay_cmp -Tracefile tracefile_dec -VOIP FOA 48 netsimoutput testv/stv3ISM48s.wav_384000_48-48_FOA_OE_JBM5.tst
// 4 ISM with metadata bitrate switching from 32 kbps to 48 kbps, 48 kHz in, 48 kHz out, BINAURAL_ROOM_IR out, object editing // 4 ISM with metadata bitrate switching from 32 kbps to 48 kbps, 48 kHz in, 48 kHz out, BINAURAL_ROOM_IR out, object editing
../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv ../scripts/switchPaths/sw_32-48k_10fr.bin 48 testv/stv4ISM48s.wav bit ../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv ../scripts/switchPaths/sw_32-48k_10fr.bin 48 testv/stv4ISM48s.wav bit
...@@ -2053,4 +2057,4 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit ...@@ -2053,4 +2057,4 @@ networkSimulator_g192 ../scripts/dly_error_profiles/dly_error_profile_5.dat bit
// 4 ISM with metadata bitrate switching from 48 kbps to 32 kbps, 48 kHz in, 48 kHz out, BINAURAL out, object editing, JBM Prof 5 // 4 ISM with metadata bitrate switching from 48 kbps to 32 kbps, 48 kHz in, 48 kHz out, BINAURAL out, object editing, JBM Prof 5
../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv ../scripts/switchPaths/sw_48-32k_10fr.bin 48 testv/stv4ISM48s.wav bit ../IVAS_cod -ism 4 testv/stvISM1.csv testv/stvISM2.csv testv/stvISM3.csv testv/stvISM4.csv ../scripts/switchPaths/sw_48-32k_10fr.bin 48 testv/stv4ISM48s.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
../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stv4ISM48s.wav_sw_48-48_BINAURAL_OE_JBM5.tst ../IVAS_dec -obj_edit ../scripts/object_edit/combined_edit.txt -no_delay_cmp -Tracefile tracefile_dec -VOIP BINAURAL 48 netsimoutput testv/stv4ISM48s.wav_sw_48-48_BINAURAL_OE_JBM5.tst
...@@ -250,14 +250,14 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1 ...@@ -250,14 +250,14 @@ eid-xor -fer -vbr -bs g192 -ep g192 bit ../scripts/dly_error_profiles/ep_5pct.g1
// Codec A at 13.20 kbps, 32kHz in, 32kHz out, DTX, JBM Prof 5 // Codec A at 13.20 kbps, 32kHz in, 32kHz out, DTX, JBM Prof 5
../IVAS_cod -dtx 13200 32 testv/stv32c.wav bit ../IVAS_cod -dtx 13200 32 testv/stv32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_13k20_32-32_DTX_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_13k20_32-32_DTX_JBM5.tst
// Codec B at 16.40 kbps, 32kHz in, 32kHz out, DTX, JBM Prof 5 // Codec B at 16.40 kbps, 32kHz in, 32kHz out, DTX, JBM Prof 5
../IVAS_cod -dtx 16400 32 testv/stv32c.wav bit ../IVAS_cod -dtx 16400 32 testv/stv32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_16k40_32-32_DTX_JBM5.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_16k40_32-32_DTX_JBM5.tst
// Codec B at 13.20 kbps, 32kHz in, 32kHz out, JBM Prof 9, Channel aware // Codec B at 13.20 kbps, 32kHz in, 32kHz out, JBM Prof 9, Channel aware
../IVAS_cod -rf 13200 32 testv/stv32c.wav bit ../IVAS_cod -rf 13200 32 testv/stv32c.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
../IVAS_dec -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_13k20_CA_32-32_JBM9.tst ../IVAS_dec -no_delay_cmp -Tracefile tracefile_dec -VOIP 32 netsimoutput testv/stv32c_13k20_CA_32-32_JBM9.tst