Commit 1d48348c authored by fotopoulou's avatar fotopoulou
Browse files

Merge branch 'main' into tmp_24-clean-up-lfe-channel-processing-within-mct

parents 9cf7497a dd187ac5
Loading
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -645,7 +645,9 @@ int main(
                fprintf( stderr, "Sampling rate must be specified on command line when using raw PCM input\n" );
                exit( -1 );
            }
#ifndef FIX_389_EXT_REND_PCM_SR
            args.sampleRate = inFileSampleRate;
#endif
            break;
        default:
            fprintf( stderr, "Error: %s\n", ivas_error_to_string( error ) );
@@ -673,7 +675,11 @@ int main(
    }

    /* === Configure === */
#ifdef FIX_392_LATE_REVERB
    if ( ( error = IVAS_REND_InitConfig( hIvasRend, args.outConfig.audioConfig ) ) != IVAS_ERR_OK )
#else
    if ( ( error = IVAS_REND_InitConfig( hIvasRend, ( args.outConfig.audioConfig == IVAS_REND_AUDIO_CONFIG_BINAURAL_ROOM ) || ( args.outConfig.audioConfig == IVAS_REND_AUDIO_CONFIG_BINAURAL ) ) ) != IVAS_ERR_OK )
#endif
    {
        fprintf( stderr, "Error in Renderer Config Init\n" );
        exit( -1 );
@@ -965,7 +971,12 @@ int main(
        }
        else
        {
#ifdef FIX_379_EXT_METADATA
            error = IVAS_REND_SetHeadRotation( hIvasRend, NULL, NULL );
            if ( ( error != IVAS_ERR_OK ) && ( error != IVAS_ERR_INVALID_OUTPUT_FORMAT ) ) // VE: TBC
#else
            if ( ( ( error = IVAS_REND_SetHeadRotation( hIvasRend, NULL, NULL ) ) != IVAS_ERR_OK ) && ( IVAS_REND_SetHeadRotation( hIvasRend, NULL, NULL ) != IVAS_ERR_INVALID_OUTPUT_FORMAT ) ) // VE: TBC
#endif
            {
                fprintf( stderr, "Error setting Head Rotation: %s\n", ivas_error_to_string( error ) );
                exit( -1 );
+12 −5
Original line number Diff line number Diff line
@@ -325,6 +325,9 @@ typedef enum
#define ISM_RADIUS_DELTA                        0.25f /* Max radius = (2^ISM_RADIUS_NBITS-1)*0.25 = 15.75 */
#define ISM_EXTENDED_METADATA_BRATE             IVAS_64k
#define ISM_EXTENDED_METADATA_BITS              1
#ifdef FIX_379_EXT_METADATA                                     
#define ISM_METADATA_RS_MAX_FRAMES              5 /* Number of frames with opposite extended metadata flags before switching */
#endif

/* Parametric ISM */
#define MAX_PARAM_ISM_NBANDS                    11
@@ -373,7 +376,11 @@ enum
{
    IND_ISM_NUM_OBJECTS,
    IND_ISM_EXTENDED_FLAG = IND_ISM_NUM_OBJECTS + MAX_NUM_OBJECTS,
#ifdef FIX_379_EXT_METADATA
    IND_ISM_METADATA_FLAG,
#else
    IND_ISM_METADATA_FLAG = IND_ISM_EXTENDED_FLAG + MAX_NUM_OBJECTS, /* EN2VE: Is this not supposed to be in the loop part below, since it is one per ISM? */
#endif
    IND_ISM_VAD_FLAG = IND_ISM_METADATA_FLAG + MAX_NUM_OBJECTS,
#ifdef DISCRETE_ISM_DTX_CNG
    IND_ISM_NOISY_SPEECH_FLAG = IND_ISM_VAD_FLAG + MAX_NUM_OBJECTS,
+7 −1
Original line number Diff line number Diff line
@@ -841,7 +841,13 @@ ivas_error ivas_ism_metadata_dec(
#ifdef DISCRETE_ISM_DTX_CNG
    ISM_DTX_DATA_DEC hISMDTX,                                   /* i/o: ISM DTX structure                           */
#endif
#ifdef FIX_379_EXT_METADATA 
    const PARAM_ISM_CONFIG_HANDLE hParamIsm,                    /* i  : Param ISM Config Handle                     */
    int16_t *ism_extended_metadata_flag,                        /* i/o: Extended metadata active in renderer        */
    int16_t *ism_extmeta_cnt                                   /* i/o: Number of change frames observed            */
#else
    const PARAM_ISM_CONFIG_HANDLE hParamIsm                     /* i  : Param ISM Config Handle                     */
#endif
);


+19 −6
Original line number Diff line number Diff line
@@ -43,7 +43,15 @@
/*----------------------------------------------------------------------------------*
 * Declaration of ISM common (encoder & decoder) structure
 *----------------------------------------------------------------------------------*/

#ifdef FIX_379_ANGLE
typedef struct
{
    int16_t last_angle1_idx; /* last frame index of coded azimuth/yaw */
    int16_t angle1_diff_cnt; /* FEC counter of consecutive differentially azimuth/yaw coded frames */
    int16_t last_angle2_idx; /* last frame index of coded elevation/pitch */
    int16_t angle2_diff_cnt; /* FEC counter of consecutive differentially elevation/pitch coded frames */
} ISM_METADATA_ANGLE, *ISM_METADATA_ANGLE_HANDLE;
#else
typedef struct
{
    int16_t last_azimuth_idx;   /* last frame index of coded azimuth */
@@ -52,7 +60,7 @@ typedef struct
    int16_t elevation_diff_cnt; /* FEC counter of consecutive differentially elevation coded frames */

} ISM_METADATA_ANGLE, *ISM_METADATA_ANGLE_HANDLE;

#endif
/* ISM metadata handle (storage for one frame of read ISM metadata) */
typedef struct
{
@@ -64,7 +72,12 @@ typedef struct
    float radius;
    float yaw;   /* azimuth orientation value read from the input metadata file */
    float pitch; /* elevation orientation value read from the input metadata file */
#ifdef FIX_379_ANGLE
    ISM_METADATA_ANGLE position_angle;    /* Angle structs for azimuth and elevation */
    ISM_METADATA_ANGLE orientation_angle; /* Angle structs for yaw and pitch */
#else
    ISM_METADATA_ANGLE angle[2]; /* Angle structs for [0] azimuth/elevation and [1] yaw/pitch */
#endif
    int16_t last_radius_idx; /* last frame index of coded radius */
    int16_t radius_diff_cnt; /* FEC counter of consecutive differentially radius coded frames */

+13 −0
Original line number Diff line number Diff line
@@ -152,6 +152,19 @@
#define FIX_382_MASA_META_FRAMING_ASYNC                 /* Nokia: Issue 382: detect potential MASA metadata framing offset */

#define SBA2MONO                                        /* FhG: Issue 365: Adapt processing of SBA mono output to be in line with stereo output (less delay, lower complexity) */
#define FIX_379_EXT_METADATA                            /* Eri: Extended metadata issues */
#define FIX_379_ANGLE                                   /* Eri: Extended metadata issues related to angle structure */


#define NOKIA_PARAMBIN_REQULARIZATION                   /* Nokia: Contribution - Configured reqularization factor for parametric binauralizer. */
#define NOKIA_ADAPTIVE_BINAURAL_PROTOS                  /* Nokia: Contribution 28: Adaptive binaural prototypes */
#define NOKIA_ADAPTIVE_BINAURAL_PROTOS_OPT              /* Nokia: enable adaptive binaural prototype complexity optimizations */

#define FIX_389_EXT_REND_PCM_SR                         /* Nokia: Issue 389: Fix assignment of sample rate with PCM input. */
#define FIX_390_EXT_REND_MASA_META_COPY                 /* Nokia: Issue 390: Fixes MASA metadata copying to renderer. */
#define FIX_392_LATE_REVERB                             /* DLB : Issue 392: keep late reverb by default off when output config is not BINAURAL_ROOM*/

#define FIX_ISM_DTX_CLICKS                              /* FhG: fix for clicks in ISM DTX for inactive to active TCX transitions */

#define ISSUE_24_CLEANUP_MCT_LFE                        /* Issue 24: Cleanup LFE path withing MCT */ 

Loading