Commit c2090f01 authored by bayers's avatar bayers
Browse files

Merge remote-tracking branch 'remotes/origin/main' into...

Merge remote-tracking branch 'remotes/origin/main' into 834-rs-number-of-existing-channels-on-the-heap-mem-wrong
parents cad82d5a b15a5701
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1334,7 +1334,7 @@ sanitizer-test-masa:
    - if: $SANITIZER_SCHEDULE_A
      when: delayed
      start_in: 21 hours
  timeout: 3 hours
  timeout: 5 hours
  script:
    - *update-ltv-repo
    - python3 ci/run_scheduled_sanitizer_test.py MASA $OUT_FORMATS_CHANNEL_BASED $OUT_FORMATS_SCENE_BASED $OUT_FORMATS_BINAURAL EXT --tests $SANITIZER_TESTS
+28 −39
Original line number Diff line number Diff line
@@ -145,10 +145,9 @@ typedef struct
#endif
#endif
    uint16_t acousticEnvironmentId;
#ifdef FIX_708_DPID_COMMAND_LINE
    int16_t Opt_dpid_on;
#endif
    uint16_t directivityPatternId[IVAS_MAX_NUM_OBJECTS];

} DecArguments;


@@ -197,7 +196,11 @@ int main(
    RotFileReader *refRotReader = NULL;
    Vector3PairFileReader *referenceVectorReader = NULL;
    ivas_error error = IVAS_ERR_UNKNOWN;
#ifdef FIX_847_OUTPUT_PCM_BUFFER
    int16_t *pcmBuf = NULL;
#else
    int16_t pcmBuf[MAX_OUTPUT_PCM_BUFFER_SIZE];
#endif
#ifdef SPLIT_REND_WITH_HEAD_ROT
    uint8_t splitRendBitsBuf[IVAS_MAX_SPLIT_REND_BITS_BUFFER_SIZE_IN_BYTES];
#endif
@@ -434,13 +437,8 @@ int main(
     * Configure the decoder
     *------------------------------------------------------------------------------------------*/

    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputConfig, arg.tsmEnabled, arg.enable5ms,
                                       arg.customLsOutputEnabled, arg.hrtfReaderEnabled, arg.enableHeadRotation, arg.enableExternalOrientation, arg.orientation_tracking, arg.renderConfigEnabled, arg.Opt_non_diegetic_pan, arg.non_diegetic_pan_gain,
#ifdef FIX_708_DPID_COMMAND_LINE
                                       arg.Opt_dpid_on,
#endif
                                       arg.acousticEnvironmentId,
                                       arg.delayCompensationEnabled ) ) != IVAS_ERR_OK )
    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputConfig, arg.tsmEnabled, arg.enable5ms, arg.customLsOutputEnabled, arg.hrtfReaderEnabled, arg.enableHeadRotation, arg.enableExternalOrientation,
                                       arg.orientation_tracking, arg.renderConfigEnabled, arg.Opt_non_diegetic_pan, arg.non_diegetic_pan_gain, arg.Opt_dpid_on, arg.acousticEnvironmentId, arg.delayCompensationEnabled ) ) != IVAS_ERR_OK )
    {
        fprintf( stderr, "\nConfigure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
        goto cleanup;
@@ -638,11 +636,7 @@ int main(

        if ( ( error = RenderConfigReader_getDirectivity( renderConfigReader, arg.directivityPatternId, renderConfig.directivity ) ) != IVAS_ERR_OK )
        {
#ifdef NONBE_FIX_730_DPID_NOT_SET_CORRECTLY
            fprintf( stderr, "Failed to get directivity patterns for one or more of IDs: %d %d %d %d\n\n", arg.directivityPatternId[0], arg.directivityPatternId[1], arg.directivityPatternId[2], arg.directivityPatternId[3] );
#else
            fprintf( stderr, "Failed to get directivity for objects: %d %d %d %d\n\n", arg.directivityPatternId[0], arg.directivityPatternId[1], arg.directivityPatternId[2], arg.directivityPatternId[3] );
#endif
            goto cleanup;
        }

@@ -753,6 +747,21 @@ int main(
        }
    }

#ifdef FIX_847_OUTPUT_PCM_BUFFER
    /*------------------------------------------------------------------------------------------*
     * Allocate output data buffer
     *------------------------------------------------------------------------------------------*/

    int16_t pcmBufSize;
    if ( ( error = IVAS_DEC_GetOutputBufferSize( hIvasDec, &pcmBufSize ) ) != IVAS_ERR_OK )
    {
        fprintf( stderr, "\nGetOutputBufferSize failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
        goto cleanup;
    }

    pcmBuf = malloc( pcmBufSize * sizeof( int16_t ) );

#endif

    /*-----------------------------------------------------------------*
     * Decoding
@@ -807,10 +816,14 @@ int main(

cleanup:

#ifdef FIX_847_OUTPUT_PCM_BUFFER
    free( pcmBuf );
#endif

#ifdef DEBUG_SBA_AUDIO_DUMP
    IVAS_DEC_GetSbaDebugParams( hIvasDec, &numOutChannels, &numTransportChannels, &pca_ingest_channels );
#endif

#endif
    if ( arg.hrtfReaderEnabled )
    {
        IVAS_DEC_HRTF_HANDLE hHrtfTD = NULL;
@@ -1002,9 +1015,7 @@ static bool parseCmdlIVAS_dec(

    arg->renderConfigEnabled = false;
    arg->renderConfigFilename = NULL;
#ifdef FIX_708_DPID_COMMAND_LINE
    arg->Opt_dpid_on = 0;
#endif

#ifdef SPLIT_REND_WITH_HEAD_ROT
    arg->outputMdFilename = NULL;
@@ -1031,11 +1042,7 @@ static bool parseCmdlIVAS_dec(
    arg->acousticEnvironmentId = 65535;
    for ( i = 0; i < IVAS_MAX_NUM_OBJECTS; ++i )
    {
#ifdef NONBE_FIX_730_DPID_NOT_SET_CORRECTLY
        arg->directivityPatternId[i] = 65535;
#else
        arg->directivityPatternId[i] = 0;
#endif
    }

    /*-----------------------------------------------------------------*
@@ -1424,17 +1431,13 @@ static bool parseCmdlIVAS_dec(
        }
        else if ( strcmp( argv_to_upper, "-DPID" ) == 0 )
        {
#ifdef FIX_708_DPID_COMMAND_LINE
            int16_t id;
            int16_t id, tmp;

            arg->Opt_dpid_on = 1;
#endif
            ++i;
            int16_t tmp;
            tmp = 0;
            while ( is_number( argv[i + tmp] ) && tmp < IVAS_MAX_NUM_OBJECTS )
            {
#ifdef FIX_708_DPID_COMMAND_LINE
                id = (int16_t) atoi( argv[i + tmp] );

                if ( !is_digits_only( argv[i + tmp] ) || id < 0 )
@@ -1445,13 +1448,9 @@ static bool parseCmdlIVAS_dec(
                }

                arg->directivityPatternId[tmp] = id;
#else
                arg->directivityPatternId[tmp] = (int16_t) atoi( argv[i + tmp] );
#endif
                ++tmp;
            }

#ifdef FIX_708_DPID_COMMAND_LINE
            if ( tmp == 0 )
            {
                if ( argc - i <= 4 || argv[i][0] == '-' )
@@ -1468,7 +1467,6 @@ static bool parseCmdlIVAS_dec(
                    return false;
                }
            }
#endif

            i += tmp;
        }
@@ -1564,12 +1562,7 @@ static bool parseCmdlIVAS_dec(
        return false;
    }

#ifdef FIX_807_VARIABLE_SPEED_DECODING
    if ( ( !arg->enableHeadRotation ) && ( !arg->enableExternalOrientation ) && ( !arg->tsmEnabled ) )
#else
    if ( ( !arg->enableHeadRotation ) && ( !arg->enableExternalOrientation ) )
#endif

    {
        arg->enable5ms = false;
    }
@@ -1663,15 +1656,11 @@ static void usage_dec( void )
    fprintf( stdout, "-force R            : Force specific binaural rendering mode, R = (TDREND, CLDFBREND),\n" );
#endif
    fprintf( stdout, "-exof File          : External orientation File for external orientation trajectory\n" );
#ifdef FIX_708_DPID_COMMAND_LINE
    fprintf( stdout, "-dpid ID            : Directivity pattern ID(s) = [ID1, ID2, ID3, ID4]. Space-separated list of up\n" );
    fprintf( stdout, "                      to 4 numbers (unsigned integers) can be specified for BINAURAL and BINAURAL_ROOM_REVERB\n" );
    fprintf( stdout, "                      output configuration. ID1, ID2, ID3, ID4 specify the directivity pattern IDs used for\n" );
    fprintf( stdout, "                      ISMs 1,2,3 and 4 respectively. This options needs to be accompanied by a render_config file,\n" );
    fprintf( stdout, "                      otherwise a default directivity pattern is used.\n" );
#else
    fprintf( stdout, "-dpid ID            : Directivity pattern ID(s) (space-separated list of up to 4 numbers can be specified) for binaural output configuration\n" );
#endif
    fprintf( stdout, "-aeid ID            : Acoustic environment ID (number >= 0) for BINAURAL_ROOM_REVERB output configuration\n" );
    fprintf( stdout, "-level level        : Complexity level, level = (1, 2, 3), will be defined after characterisation. \n" );
    fprintf( stdout, "                      Currently, all values default to level 3 (full functionality).\n" );
+8 −16
Original line number Diff line number Diff line
@@ -100,7 +100,7 @@ typedef struct
    uint16_t numObjects;
    IsmFileReader *ismReaders[RENDERER_MAX_ISM_INPUTS];
    uint32_t numPositions[RENDERER_MAX_ISM_INPUTS];
    IVAS_REND_AudioObjectPosition *positions[RENDERER_MAX_ISM_INPUTS]; /* size: [RENDERER_MAX_ISM_INPUTS][numPositions[object_index]] */
    IVAS_ISM_METADATA *positions[RENDERER_MAX_ISM_INPUTS]; /* size: [RENDERER_MAX_ISM_INPUTS][numPositions[object_index]] */
    uint16_t *positionDurations[RENDERER_MAX_ISM_INPUTS];  /* size: [RENDERER_MAX_ISM_INPUTS][numPositions[object_index]] */
    uint32_t currentPositionIdxs[RENDERER_MAX_ISM_INPUTS]; /* Index of current position as listed in the metadata file */
    uint16_t durationCounters[RENDERER_MAX_ISM_INPUTS];    /* Number of frames spent at current position */
@@ -123,7 +123,7 @@ typedef struct

typedef struct
{
    IVAS_REND_AudioObjectPosition positions[RENDERER_MAX_ISM_INPUTS];
    IVAS_ISM_METADATA positions[RENDERER_MAX_ISM_INPUTS];
    int16_t numObjects;
} ObjectPositionBuffer;

@@ -384,11 +384,7 @@ static const CmdLnParser_Option cliOptions[] = {
        .id = CmdLnOptionId_directivityPatternId,
        .match = "ism_directivity_pattern_id",
        .matchShort = "dpid",
#ifdef FIX_708_DPID_COMMAND_LINE
        .description = "Directivity pattern ID(s) = [ID1, ID2, ID3, ID4]. Space-separated list of up to 4 numbers (unsigned integers) can be specified for BINAURAL and BINAURAL_ROOM_REVERB output configuration.\nID1, ID2, ID3, ID4 specify the directivity pattern IDs used for ISMs 1,2,3 and 4 respectively.\nThis options needs to be accompanied by a render_config file, otherwise a default directivity pattern is used.",
#else
        .description = "Directivity pattern ID(s) (space-separated list of up to 4 numbers can be specified) for binaural output configuration",
#endif
    },
    {
        .id = CmdLnOptionId_acousticEnvironmentId,
@@ -437,7 +433,7 @@ static int8_t parseUint32( const char *line, uint32_t *ret );

static int8_t parseInt32( const char *line, int32_t *ret );

static void parseObjectPosition( char *line, IVAS_REND_AudioObjectPosition *position, uint16_t *positionDuration );
static void parseObjectPosition( char *line, IVAS_ISM_METADATA *position, uint16_t *positionDuration );

static void parseMetadata( char *metadataString, char *inDir, InputConfig *inConfig, IsmPositionProvider *positionProvider, MasaFileReader **masaReaders, LfeRoutingConfig **lfeRoutingConfigs );

@@ -2640,11 +2636,7 @@ static CmdlnArgs defaultArgs(

    for ( int32_t i = 0; i < RENDERER_MAX_ISM_INPUTS; ++i )
    {
#ifdef NONBE_FIX_730_DPID_NOT_SET_CORRECTLY
        args.directivityPatternId[i] = 65535;
#else
        args.directivityPatternId[i] = 0;
#endif
    }

    args.acousticEnvironmentId = 65535;
@@ -3291,7 +3283,7 @@ static void parseOptionalInputValues(

static void parseObjectPosition(
    char *line,
    IVAS_REND_AudioObjectPosition *position,
    IVAS_ISM_METADATA *position,
    uint16_t *positionDuration )
{
    char *endptr;
@@ -3340,7 +3332,7 @@ static void parseIsm(
    if ( parseUint32( line, &numberOfObjectPositionsToRead ) == 0 )
    {
        positionProvider->numPositions[idx] = numberOfObjectPositionsToRead;
        positionProvider->positions[idx] = malloc( numberOfObjectPositionsToRead * sizeof( IVAS_REND_AudioObjectPosition ) );
        positionProvider->positions[idx] = malloc( numberOfObjectPositionsToRead * sizeof( IVAS_ISM_METADATA ) );
        positionProvider->positionDurations[idx] = malloc( numberOfObjectPositionsToRead * sizeof( uint16_t ) );

        for ( i = 0; i < numberOfObjectPositionsToRead; ++i )
+106 −102
Original line number Diff line number Diff line
@@ -48,6 +48,7 @@
#define IVAS_MAX_FRAME_SIZE     ( 48000 / IVAS_NUM_FRAMES_PER_SEC )

#define IVAS_MAX_BITS_PER_FRAME ( 512000 / IVAS_NUM_FRAMES_PER_SEC )

#define IVAS_MAX_NUM_OBJECTS        4
#define IVAS_MAX_INPUT_CHANNELS     16
#define IVAS_MAX_OUTPUT_CHANNELS    16
@@ -55,14 +56,9 @@
#define IVAS_CLDFB_NO_CHANNELS_MAX  60
#define IVAS_MAX_INPUT_LFE_CHANNELS 4


#define IVAS_MAX_PARAM_SPATIAL_SUBFRAMES 4

#define IVAS_ROOM_ABS_COEFF 6
#ifdef SPLIT_REND_WITH_HEAD_ROT
#define IVAS_MAX_SPLIT_REND_BITRATE                   768000
#define IVAS_MAX_SPLIT_REND_BITS_BUFFER_SIZE_IN_BYTES ( ( ( (int32_t) IVAS_MAX_SPLIT_REND_BITRATE / IVAS_NUM_FRAMES_PER_SEC ) + 7 ) >> 3 )
#endif

/*----------------------------------------------------------------------------------*
 * Common API enum for output audio configurations
@@ -100,7 +96,7 @@ typedef enum _IVAS_AUDIO_CONFIG


/*----------------------------------------------------------------------------------*
 * Common API structures
 * Common API structures and enums
 *----------------------------------------------------------------------------------*/

typedef enum _IVAS_ENC_FEC_INDICATOR
@@ -108,6 +104,7 @@ typedef enum _IVAS_ENC_FEC_INDICATOR
    IVAS_ENC_FEC_LO,
    IVAS_ENC_FEC_HI,
    IVAS_ENC_FEC_UNDEFINED = 0xffff

} IVAS_ENC_FEC_INDICATOR;

typedef struct _IVAS_ENC_CHANNEL_AWARE_CONFIG
@@ -115,6 +112,7 @@ typedef struct _IVAS_ENC_CHANNEL_AWARE_CONFIG
    int16_t channelAwareModeEnabled;
    IVAS_ENC_FEC_INDICATOR fec_indicator;
    int16_t fec_offset;

} IVAS_ENC_CHANNEL_AWARE_CONFIG;

typedef struct _IVAS_ISM_METADATA
@@ -127,6 +125,7 @@ typedef struct _IVAS_ISM_METADATA
    float yaw;
    float pitch;
    int16_t non_diegetic_flag;

} IVAS_ISM_METADATA;

typedef struct
@@ -135,7 +134,69 @@ typedef struct

} IVAS_QUATERNION;

typedef struct
{
    float x, y, z;

} IVAS_VECTOR3;

typedef enum
{
    IVAS_HEAD_ORIENT_TRK_NONE,
    IVAS_HEAD_ORIENT_TRK_REF,
    IVAS_HEAD_ORIENT_TRK_AVG,
    IVAS_HEAD_ORIENT_TRK_REF_VEC,
    IVAS_HEAD_ORIENT_TRK_REF_VEC_LEV

} IVAS_HEAD_ORIENT_TRK_T;

typedef struct ivas_masa_metadata_frame_struct *IVAS_MASA_METADATA_HANDLE;
typedef struct ivas_masa_decoder_ext_out_meta_struct *IVAS_MASA_DECODER_EXT_OUT_META_HANDLE;

typedef struct TDREND_HRFILT_FiltSet_struct *IVAS_DEC_HRTF_HANDLE;
typedef struct ivas_hrtfs_crend_structure *IVAS_DEC_HRTF_CREND_HANDLE;
typedef struct ivas_hrtfs_fastconv_struct *IVAS_DEC_HRTF_FASTCONV_HANDLE;
typedef struct ivas_hrtfs_parambin_struct *IVAS_DEC_HRTF_PARAMBIN_HANDLE;
typedef struct cldfb_filter_bank_struct *IVAS_CLDFB_FILTER_BANK_HANDLE;

typedef struct ivas_LS_setup_custom *IVAS_LSSETUP_CUSTOM_HANDLE;
typedef struct ivas_LS_setup_custom IVAS_LSSETUP_CUSTOM_STRUCT;

typedef struct _IVAS_LS_CUSTOM_LAYOUT
{
    int16_t num_spk;
    float azimuth[IVAS_MAX_OUTPUT_CHANNELS];
    float elevation[IVAS_MAX_OUTPUT_CHANNELS];
    int16_t num_lfe;
    int16_t lfe_idx[IVAS_MAX_OUTPUT_CHANNELS];

} IVAS_CUSTOM_LS_DATA;

typedef struct _IVAS_JBM_TRACE_DATA
{
    uint32_t systemTimestamp_ms;
    uint16_t extBufferedSamples;
    uint16_t lastDecodedWasActive;
    int32_t output_Fs;
    int16_t dataUnit_flag;
    uint16_t sequenceNumber;
    uint32_t timeStamp;
    uint32_t rcvTime;

    int16_t partial_frame;
    int16_t partialCopyOffset;

} IVAS_JBM_TRACE_DATA;


#ifdef SPLIT_REND_WITH_HEAD_ROT
/*----------------------------------------------------------------------------------*
 * Split rendering API constants, structures, and enums
 *----------------------------------------------------------------------------------*/

#define IVAS_MAX_SPLIT_REND_BITRATE                   768000
#define IVAS_MAX_SPLIT_REND_BITS_BUFFER_SIZE_IN_BYTES ( ( ( (int32_t) IVAS_MAX_SPLIT_REND_BITRATE / IVAS_NUM_FRAMES_PER_SEC ) + 7 ) >> 3 )

typedef enum
{
    DEFAULT_AXIS,
@@ -145,12 +206,14 @@ typedef enum
    YAW_PITCH,
    YAW_ROLL,
    PITCH_ROLL

} IVAS_SPLIT_REND_ROT_AXIS;

typedef enum
{
    IVAS_SPLIT_REND_POSE_CORRECTION_MODE_NONE,
    IVAS_SPLIT_REND_POSE_CORRECTION_MODE_CLDFB,

} IVAS_SPLIT_REND_POSE_CORRECTION_MODE;

typedef enum
@@ -159,6 +222,7 @@ typedef enum
    IVAS_SPLIT_REND_CODEC_LC3PLUS,
    IVAS_SPLIT_REND_CODEC_DEFAULT, /* Will use LCLD for CLDFB rendering paths and LC3plus for TD rendering paths */
    IVAS_SPLIT_REND_CODEC_NONE

} IVAS_SPLIT_REND_CODEC;

typedef enum
@@ -168,6 +232,7 @@ typedef enum
    IVAS_SPLIT_REND_RENDERER_SELECTION_PARAMBIN,
    IVAS_SPLIT_REND_RENDERER_SELECTION_TDREND,
    IVAS_SPLIT_REND_RENDERER_SELECTION_DEFAULT,

} IVAS_SPLIT_REND_RENDERER_SELECTION;

typedef struct ivas_split_rend_bits_t
@@ -179,33 +244,32 @@ typedef struct ivas_split_rend_bits_t
    int16_t codec_frame_size_ms;
    IVAS_SPLIT_REND_CODEC codec;
    IVAS_SPLIT_REND_POSE_CORRECTION_MODE pose_correction;
} ivas_split_rend_bits_t, IVAS_SPLIT_REND_BITS_DATA, *IVAS_SPLIT_REND_BITS_HANDLE;
#endif

typedef struct
{
    float x, y, z;
} IVAS_VECTOR3;
} ivas_split_rend_bits_t, IVAS_SPLIT_REND_BITS_DATA, *IVAS_SPLIT_REND_BITS_HANDLE;

typedef enum
typedef struct _IVAS_SPLIT_REND_CONFIG
{
    IVAS_HEAD_ORIENT_TRK_NONE,
    IVAS_HEAD_ORIENT_TRK_REF,
    IVAS_HEAD_ORIENT_TRK_AVG,
    IVAS_HEAD_ORIENT_TRK_REF_VEC,
    IVAS_HEAD_ORIENT_TRK_REF_VEC_LEV

} IVAS_HEAD_ORIENT_TRK_T;

typedef struct ivas_masa_metadata_frame_struct *IVAS_MASA_METADATA_HANDLE;
typedef struct ivas_masa_decoder_ext_out_meta_struct *IVAS_MASA_DECODER_EXT_OUT_META_HANDLE;
    int32_t splitRendBitRate;    /*Bit rate for split rendering mode, if "pcm_out" is set then "splitRendBitRate" is used as a limit for MD bitrate */
    int16_t hq_mode;             /*High quality 3DOF mode with additional side information. Requires more pre-renditions. */
    int16_t dof;                 /*flag to specify if pose correction is needed for 1, 2 or 3 degree of freedoms*/
                                 /*The axis can be set dynamically per frame based on a file input */
                                 /*possible values:
                                 1 - (1dof correction. By default YAW correction)
                                 2 - (2dof correction. By default YAW and PITCH correction)
                                 3 - (3dof correction. By default YAW, PITCH and ROLL correction)
                                 */
    int16_t codec_delay_ms;      /*PLACEHOLDER (currently being ignored) : look ahead delay of the codec that is used to code BIN signal output of pre-renderer*/
    int16_t codec_frame_size_ms; /*Codec frame size in milliseconds, only relevant with LC3plus */
    IVAS_SPLIT_REND_POSE_CORRECTION_MODE poseCorrectionMode;
    IVAS_SPLIT_REND_CODEC codec;
    IVAS_SPLIT_REND_RENDERER_SELECTION rendererSelection;

typedef struct TDREND_HRFILT_FiltSet_struct *IVAS_DEC_HRTF_HANDLE;
typedef struct ivas_hrtfs_crend_structure *IVAS_DEC_HRTF_CREND_HANDLE;
typedef struct ivas_hrtfs_fastconv_struct *IVAS_DEC_HRTF_FASTCONV_HANDLE;
typedef struct ivas_hrtfs_parambin_struct *IVAS_DEC_HRTF_PARAMBIN_HANDLE;
} IVAS_SPLIT_REND_CONFIG_DATA;
#endif

typedef struct cldfb_filter_bank_struct *IVAS_CLDFB_FILTER_BANK_HANDLE;
/*----------------------------------------------------------------------------------*
 * Renderer API structures and enums
 *----------------------------------------------------------------------------------*/

#ifdef DEBUGGING
typedef enum
@@ -213,20 +277,10 @@ typedef enum
    IVAS_RENDER_TYPE_OVERRIDE_NONE,
    IVAS_RENDER_TYPE_OVERRIDE_CREND,
    IVAS_RENDER_TYPE_OVERRIDE_FASTCONV

} IVAS_RENDER_TYPE_OVERRIDE;
#endif

typedef struct
{
    float azimuth;
    float elevation;
    float radius;
    float yaw;
    float pitch;
    int16_t non_diegetic_flag;

} IVAS_REND_AudioObjectPosition;

typedef struct _IVAS_ROOM_ACOUSTICS_CONFIG
{
    int16_t override;
@@ -246,27 +300,6 @@ typedef struct _IVAS_ROOM_ACOUSTICS_CONFIG

} IVAS_ROOM_ACOUSTICS_CONFIG_DATA;

#ifdef SPLIT_REND_WITH_HEAD_ROT

typedef struct _IVAS_SPLIT_REND_CONFIG
{
    int32_t splitRendBitRate;    /*Bit rate for split rendering mode, if "pcm_out" is set then "splitRendBitRate" is used as a limit for MD bitrate */
    int16_t hq_mode;             /*High quality 3DOF mode with additional side information. Requires more pre-renditions. */
    int16_t dof;                 /*flag to specify if pose correction is needed for 1, 2 or 3 degree of freedoms*/
                                 /*The axis can be set dynamically per frame based on a file input */
                                 /*possible values:
                                 1 - (1dof correction. By default YAW correction)
                                 2 - (2dof correction. By default YAW and PITCH correction)
                                 3 - (3dof correction. By default YAW, PITCH and ROLL correction)
                                 */
    int16_t codec_delay_ms;      /*PLACEHOLDER (currently being ignored) : look ahead delay of the codec that is used to code BIN signal output of pre-renderer*/
    int16_t codec_frame_size_ms; /*Codec frame size in milliseconds, only relevant with LC3plus */
    IVAS_SPLIT_REND_POSE_CORRECTION_MODE poseCorrectionMode;
    IVAS_SPLIT_REND_CODEC codec;
    IVAS_SPLIT_REND_RENDERER_SELECTION rendererSelection;
} IVAS_SPLIT_REND_CONFIG_DATA;
#endif

typedef struct _IVAS_RENDER_CONFIG
{
#ifdef DEBUGGING
@@ -277,36 +310,7 @@ typedef struct _IVAS_RENDER_CONFIG
    IVAS_SPLIT_REND_CONFIG_DATA split_rend_config;
#endif
    float directivity[IVAS_MAX_NUM_OBJECTS * 3];
} IVAS_RENDER_CONFIG_DATA, *IVAS_RENDER_CONFIG_HANDLE;

typedef struct _IVAS_LS_CUSTOM_LAYOUT
{
    int16_t num_spk;
    float azimuth[IVAS_MAX_OUTPUT_CHANNELS];
    float elevation[IVAS_MAX_OUTPUT_CHANNELS];
    int16_t num_lfe;
    int16_t lfe_idx[IVAS_MAX_OUTPUT_CHANNELS];

} IVAS_CUSTOM_LS_DATA;

typedef struct ivas_LS_setup_custom *IVAS_LSSETUP_CUSTOM_HANDLE;
typedef struct ivas_LS_setup_custom IVAS_LSSETUP_CUSTOM_STRUCT;


typedef struct _IVAS_JBM_TRACE_DATA
{
    uint32_t systemTimestamp_ms;
    uint16_t extBufferedSamples;
    uint16_t lastDecodedWasActive;
    int32_t output_Fs;
    int16_t dataUnit_flag;
    uint16_t sequenceNumber;
    uint32_t timeStamp;
    uint32_t rcvTime;

    int16_t partial_frame;
    int16_t partialCopyOffset;

} IVAS_JBM_TRACE_DATA;
} IVAS_RENDER_CONFIG_DATA, *IVAS_RENDER_CONFIG_HANDLE;

#endif /* COMMON_API_TYPES_H */
+7 −4
Original line number Diff line number Diff line
@@ -65,6 +65,9 @@ typedef enum
    IVAS_ERR_INVALID_FEC_CONFIG,
    IVAS_ERR_INVALID_FEC_OFFSET,
    IVAS_ERR_INVALID_INPUT_BUFFER_SIZE,
#ifdef FIX_847_OUTPUT_PCM_BUFFER
    IVAS_ERR_INVALID_OUTPUT_BUFFER_SIZE,
#endif
    IVAS_ERR_DTX_NOT_SUPPORTED,
    IVAS_ERR_UNEXPECTED_NULL_POINTER,
    IVAS_ERR_METADATA_NOT_EXPECTED,
@@ -75,9 +78,7 @@ typedef enum
    IVAS_ERR_INVALID_OUTPUT_FORMAT,
    IVAS_ERR_HEAD_ROTATION_NOT_SUPPORTED,
    IVAS_ERR_EXT_ORIENTATION_NOT_SUPPORTED,
#ifdef FIX_708_DPID_COMMAND_LINE
    IVAS_ERR_DIRECTIVITY_NOT_SUPPORTED,
#endif
    IVAS_ERR_ACOUSTIC_ENVIRONMENT_NOT_SUPPORTED,
    IVAS_ERR_INVALID_HRTF,
    IVAS_ERR_INVALID_INPUT_FORMAT,
@@ -219,6 +220,10 @@ static inline const char *ivas_error_to_string( ivas_error error_code )
            return "Invalid FEC offset";
        case IVAS_ERR_INVALID_INPUT_BUFFER_SIZE:
            return "Invalid input buffer size";
#ifdef FIX_847_OUTPUT_PCM_BUFFER
        case IVAS_ERR_INVALID_OUTPUT_BUFFER_SIZE:
            return "Invalid output buffer size";
#endif
        case IVAS_ERR_DTX_NOT_SUPPORTED:
            return "DTX is not supported in this IVAS format and element mode";
        case IVAS_ERR_UNEXPECTED_NULL_POINTER:
@@ -253,10 +258,8 @@ static inline const char *ivas_error_to_string( ivas_error error_code )
#endif
        case IVAS_ERR_EXT_ORIENTATION_NOT_SUPPORTED:
            return "External orientation not supported";
#ifdef FIX_708_DPID_COMMAND_LINE
        case IVAS_ERR_DIRECTIVITY_NOT_SUPPORTED:
            return "Directivity not supported";
#endif
        case IVAS_ERR_ACOUSTIC_ENVIRONMENT_NOT_SUPPORTED:
            return "Acoustic environment not supported";
        case IVAS_ERR_INVALID_HRTF:
Loading