Commit 6938ec27 authored by vaclav's avatar vaclav
Browse files

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

- Merge remote-tracking branch 'remotes/origin/main' into 731-etx-output-for-omasa-and-osba-api_5ms-wrong-implementation-in-decodeg192
parents 1baa2feb 32aa5004
Loading
Loading
Loading
Loading
Loading
+58 −58
Original line number Diff line number Diff line
@@ -96,7 +96,7 @@ typedef struct
    char *outputWavFilename;
    IVAS_DEC_MODE decMode;
    int32_t output_Fs;
    AUDIO_CONFIG outputConfig;
    IVAS_AUDIO_CONFIG outputConfig;
    bool quietModeEnabled;
    bool delayCompensationEnabled;
    bool voipMode;
@@ -265,11 +265,11 @@ int main(
    }

#ifdef SPLIT_REND_WITH_HEAD_ROT
    if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
    {
        fprintf( stdout, "Output metadata file:   %s\n", arg.outputWavFilename );
    }
    else if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    else if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        fprintf( stdout, "Output synthesis file:  %s\n", arg.outputWavFilename );
        fprintf( stdout, "Output metadata file:   %s\n", arg.outputMdFilename );
@@ -287,7 +287,7 @@ int main(
    if ( arg.hrtfReaderEnabled )
    {
        /* sanity check */
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        {
            arg.hrtfReaderEnabled = false;
            fprintf( stderr, "\nError: HRTF binary file cannot be used in this output configuration.\n\n" );
@@ -309,9 +309,9 @@ int main(
    if ( arg.enableHeadRotation )
    {
        /* sanity check */
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB
#ifdef SPLIT_REND_WITH_HEAD_ROT
             && arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_PCM
             && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM
#endif
        )
        {
@@ -333,7 +333,7 @@ int main(
    if ( arg.enableReferenceRotation )
    {
        /* sanity check */
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        {
            fprintf( stderr, "\nError: Reference rotation file cannot be used in this output configuration.\n\n" );
            goto cleanup;
@@ -360,7 +360,7 @@ int main(
    if ( arg.enableReferenceVectorTracking )
    {
        /* sanity check */
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        {
            fprintf( stderr, "\nError: Reference vector trajectory file cannot be used in this output configuration.\n\n" );
            goto cleanup;
@@ -413,9 +413,9 @@ int main(
    if ( arg.renderConfigEnabled )
    {
        /* sanity check */
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB
#ifdef SPLIT_REND_WITH_HEAD_ROT
             && arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_PCM
             && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM
#endif
        )
        {
@@ -453,7 +453,7 @@ int main(
     *------------------------------------------------------------------------------------------*/

#ifdef SPLIT_REND_WITH_HEAD_ROT
    if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        if ( ( error = IVAS_DEC_EnableSplitRendering( hIvasDec ) ) != IVAS_ERR_OK )
        {
@@ -593,14 +593,14 @@ int main(

        /* sanity check */
#ifdef SPLIT_REND_WITH_HEAD_ROT
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB &&
             arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB &&
             arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
        {
            fprintf( stderr, "\nExternal Renderer Config is supported only when binaural output configurations is used as output OR when Split rendering mode is enabled. Exiting. \n" );
            goto cleanup;
        }
#else
        if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR && arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        {
            fprintf( stderr, "\nExternal Renderer Config is supported only for binaural output configurations. Exiting. \n\n" );
            goto cleanup;
@@ -648,9 +648,9 @@ int main(
            goto cleanup;
        }

        if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB )
        {
            if ( ( error = RenderConfigReader_getAcousticEnvironment( renderConfigReader, arg.acousticEnvironmentId, &renderConfig.room_acoustics ) ) == IVAS_ERR_OK )
            if ( ( error = RenderConfigReader_getAcousticEnvironment( renderConfigReader, arg.acousticEnvironmentId, &renderConfig.roomAcoustics ) ) == IVAS_ERR_OK )
            {
                if ( RenderConfigReader_checkValues( &renderConfig ) != IVAS_ERR_OK )
                {
@@ -667,7 +667,7 @@ int main(
                fprintf( stderr, "Failed to get acoustic environment with ID: %d\n\n", arg.acousticEnvironmentId );
                goto cleanup;
            }
            renderConfig.room_acoustics.override = true;
            renderConfig.roomAcoustics.override = true;
        }

        if ( ( error = IVAS_DEC_FeedRenderConfig( hIvasDec, renderConfig ) ) != IVAS_ERR_OK )
@@ -868,10 +868,10 @@ cleanup:
 * Translate command-line argument to output configuration
 *---------------------------------------------------------------------*/

static AUDIO_CONFIG cmdline2config(
static IVAS_AUDIO_CONFIG cmdline2config(
    char *argv )
{
    AUDIO_CONFIG output_config;
    IVAS_AUDIO_CONFIG output_config;

    char argv_to_upper[FILENAME_MAX];

@@ -881,73 +881,73 @@ static AUDIO_CONFIG cmdline2config(

    if ( strcmp( argv_to_upper, "EXT" ) == 0 ) /* external renderer */
    {
        output_config = AUDIO_CONFIG_EXTERNAL;
        output_config = IVAS_AUDIO_CONFIG_EXTERNAL;
    }
    else if ( strcmp( argv_to_upper, "MONO" ) == 0 )
    {
        output_config = AUDIO_CONFIG_MONO;
        output_config = IVAS_AUDIO_CONFIG_MONO;
    }
    else if ( strcmp( argv_to_upper, "STEREO" ) == 0 )
    {
        output_config = AUDIO_CONFIG_STEREO;
        output_config = IVAS_AUDIO_CONFIG_STEREO;
    }
    else if ( strcmp( argv_to_upper, "5_1" ) == 0 )
    {
        output_config = AUDIO_CONFIG_5_1;
        output_config = IVAS_AUDIO_CONFIG_5_1;
    }
    else if ( strcmp( argv_to_upper, "7_1" ) == 0 )
    {
        output_config = AUDIO_CONFIG_7_1;
        output_config = IVAS_AUDIO_CONFIG_7_1;
    }
    else if ( strcmp( argv_to_upper, "5_1_2" ) == 0 )
    {
        output_config = AUDIO_CONFIG_5_1_2;
        output_config = IVAS_AUDIO_CONFIG_5_1_2;
    }
    else if ( strcmp( argv_to_upper, "5_1_4" ) == 0 )
    {
        output_config = AUDIO_CONFIG_5_1_4;
        output_config = IVAS_AUDIO_CONFIG_5_1_4;
    }
    else if ( strcmp( argv_to_upper, "7_1_4" ) == 0 )
    {
        output_config = AUDIO_CONFIG_7_1_4;
        output_config = IVAS_AUDIO_CONFIG_7_1_4;
    }
    else if ( strcmp( argv_to_upper, "FOA" ) == 0 )
    {
        output_config = AUDIO_CONFIG_FOA;
        output_config = IVAS_AUDIO_CONFIG_FOA;
    }
    else if ( strcmp( argv_to_upper, "HOA2" ) == 0 )
    {
        output_config = AUDIO_CONFIG_HOA2;
        output_config = IVAS_AUDIO_CONFIG_HOA2;
    }
    else if ( strcmp( argv_to_upper, "HOA3" ) == 0 )
    {
        output_config = AUDIO_CONFIG_HOA3;
        output_config = IVAS_AUDIO_CONFIG_HOA3;
    }
    else if ( strcmp( argv_to_upper, "BINAURAL" ) == 0 )
    {
        output_config = AUDIO_CONFIG_BINAURAL;
        output_config = IVAS_AUDIO_CONFIG_BINAURAL;
    }
#ifdef SPLIT_REND_WITH_HEAD_ROT
    else if ( strcmp( argv_to_upper, "BINAURAL_SPLIT_CODED" ) == 0 )
    {
        output_config = AUDIO_CONFIG_BINAURAL_SPLIT_CODED;
        output_config = IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED;
    }
    else if ( strcmp( argv_to_upper, "BINAURAL_SPLIT_PCM" ) == 0 )
    {
        output_config = AUDIO_CONFIG_BINAURAL_SPLIT_PCM;
        output_config = IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM;
    }
#endif
    else if ( strcmp( argv_to_upper, "BINAURAL_ROOM_IR" ) == 0 )
    {
        output_config = AUDIO_CONFIG_BINAURAL_ROOM_IR;
        output_config = IVAS_AUDIO_CONFIG_BINAURAL_ROOM_IR;
    }
    else if ( strcmp( argv_to_upper, "BINAURAL_ROOM_REVERB" ) == 0 )
    {
        output_config = AUDIO_CONFIG_BINAURAL_ROOM_REVERB;
        output_config = IVAS_AUDIO_CONFIG_BINAURAL_ROOM_REVERB;
    }
    else
    {
        output_config = AUDIO_CONFIG_LS_CUSTOM;
        output_config = IVAS_AUDIO_CONFIG_LS_CUSTOM;
    }

    return output_config;
@@ -977,7 +977,7 @@ static bool parseCmdlIVAS_dec(
#endif
#endif
    arg->output_Fs = 48000;
    arg->outputConfig = AUDIO_CONFIG_MONO;
    arg->outputConfig = IVAS_AUDIO_CONFIG_MONO;
    arg->decMode = IVAS_DEC_MODE_IVAS;
    arg->quietModeEnabled = false;
    arg->delayCompensationEnabled = true;
@@ -1507,13 +1507,13 @@ static bool parseCmdlIVAS_dec(
    if ( i < argc - 3 )
    {
        arg->outputConfig = cmdline2config( argv[i] );
        if ( arg->outputConfig == AUDIO_CONFIG_LS_CUSTOM )
        if ( arg->outputConfig == IVAS_AUDIO_CONFIG_LS_CUSTOM )
        {
            arg->customLsOutputEnabled = true;
            arg->customLsSetupFilename = argv[i];
        }
        i++;
        if ( ( arg->Opt_non_diegetic_pan ) && ( arg->outputConfig != AUDIO_CONFIG_STEREO ) )
        if ( ( arg->Opt_non_diegetic_pan ) && ( arg->outputConfig != IVAS_AUDIO_CONFIG_STEREO ) )
        {
            fprintf( stderr, "Error: non-diegetic panning is supported in stereo only\n\n" );
            usage_dec();
@@ -1522,11 +1522,11 @@ static bool parseCmdlIVAS_dec(
    }
    else
    {
        arg->outputConfig = AUDIO_CONFIG_MONO;
        arg->outputConfig = IVAS_AUDIO_CONFIG_MONO;
        arg->decMode = IVAS_DEC_MODE_EVS;
        if ( ( arg->Opt_non_diegetic_pan ) )
        {
            arg->outputConfig = AUDIO_CONFIG_STEREO;
            arg->outputConfig = IVAS_AUDIO_CONFIG_STEREO;
        }
    }

@@ -1753,7 +1753,7 @@ static ivas_error initOnFirstGoodFrame(
    }

#ifdef SPLIT_REND_WITH_HEAD_ROT
    if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        pFullDelayNumSamples[0] = 0;
    }
@@ -1780,7 +1780,7 @@ static ivas_error initOnFirstGoodFrame(
    }

#ifdef SPLIT_REND_WITH_HEAD_ROT
    if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
    {
        /* Open split rendering metadata writer */
        int16_t delayNumSamples_temp[3];
@@ -1792,7 +1792,7 @@ static ivas_error initOnFirstGoodFrame(
            return error;
        }

        if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
        if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
        {
            if ( ( error = split_rend_writer_open( splitRendWriter, arg.outputWavFilename, delayNumSamples_temp[0], delayTimeScale_temp ) ) != IVAS_ERR_OK )
            {
@@ -1810,7 +1810,7 @@ static ivas_error initOnFirstGoodFrame(
        }
    }

    if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
    if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
    {
#endif
        /* Open audio writer and write all previously skipped bad frames now that frame size is known */
@@ -1890,7 +1890,7 @@ static ivas_error initOnFirstGoodFrame(
    free( zeroBuf );

    /* Open other output files if EXT output config - now details about ISM or MASA are known */
    if ( arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
    {
        if ( ( error = IVAS_DEC_GetFormat( hIvasDec, pBsFormat ) ) != IVAS_ERR_OK )
        {
@@ -1950,7 +1950,7 @@ static ivas_error initOnFirstGoodFrame(
            if ( numInitialBadFrames > 0 )
            {
                /* Duplicate good first frame metadata to fill the beginning of stream. */
                MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta = NULL;
                IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta = NULL;
                if ( ( error = IVAS_DEC_GetMasaMetadata( hIvasDec, &hMasaExtOutMeta, 0 ) ) != IVAS_ERR_OK )
                {
                    fprintf( stderr, "\nError in IVAS_DEC_GetMasaMetadata: %s\n", IVAS_DEC_GetErrorMessage( error ) );
@@ -2316,7 +2316,7 @@ static ivas_error decodeG192(
            }

#ifdef SPLIT_REND_WITH_HEAD_ROT
            if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
            if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
            {
                if ( ( error = IVAS_DEC_GetSplitBinauralBitstream( hIvasDec, (void *) ( pcmBuf + nOutChannels * nSamplesRendered ), splitRendBitsBuf, &nSamplesRendered_loop, &needNewFrame ) ) != IVAS_ERR_OK )
                {
@@ -2392,7 +2392,7 @@ static ivas_error decodeG192(
        if ( decodedGoodFrame )
        {
#ifdef SPLIT_REND_WITH_HEAD_ROT
            if ( arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
            if ( arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED || arg.outputConfig == IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
            {
                IVAS_SPLIT_REND_BITS_DATA splitRendBits;

@@ -2409,7 +2409,7 @@ static ivas_error decodeG192(
                }
            }

            if ( arg.outputConfig != AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
            if ( arg.outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_CODED )
            {
#endif
                if ( delayNumSamples < nOutSamples )
@@ -2431,7 +2431,7 @@ static ivas_error decodeG192(
        }

        /* Write ISm metadata to external file(s) */
        if ( decodedGoodFrame && arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
        if ( decodedGoodFrame && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
        {
            if ( bsFormat == IVAS_DEC_BS_OBJ || bsFormat == IVAS_DEC_BS_MASA_ISM || bsFormat == IVAS_DEC_BS_SBA_ISM )
            {
@@ -2461,7 +2461,7 @@ static ivas_error decodeG192(

            if ( bsFormat == IVAS_DEC_BS_MASA || bsFormat == IVAS_DEC_BS_MASA_ISM )
            {
                MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                if ( ( error = IVAS_DEC_GetMasaMetadata( hIvasDec, &hMasaExtOutMeta, 0 ) ) != IVAS_ERR_OK )
                {
                    fprintf( stderr, "\nError in IVAS_DEC_GetMasaMetadata: %s\n", IVAS_DEC_GetErrorMessage( error ) );
@@ -2596,7 +2596,7 @@ static ivas_error decodeG192(
        }

        /* Write ISm metadata to external file(s) */
        if ( decodedGoodFrame && arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
        if ( decodedGoodFrame && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
        {
            if ( bsFormat == IVAS_DEC_BS_OBJ || bsFormat == IVAS_DEC_BS_MASA_ISM || bsFormat == IVAS_DEC_BS_SBA_ISM )
            {
@@ -2626,7 +2626,7 @@ static ivas_error decodeG192(

            if ( bsFormat == IVAS_DEC_BS_MASA || bsFormat == IVAS_DEC_BS_MASA_ISM )
            {
                MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                if ( ( error = IVAS_DEC_GetMasaMetadata( hIvasDec, &hMasaExtOutMeta, 0 ) ) != IVAS_ERR_OK )
                {
                    fprintf( stderr, "\nError in IVAS_DEC_GetMasaMetadata: %s\n", IVAS_DEC_GetErrorMessage( error ) );
@@ -2670,7 +2670,7 @@ static ivas_error decodeG192(
    }

    /* Print output metadata file name(s) */
    if ( arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
    {
        if ( bsFormat == IVAS_DEC_BS_OBJ || bsFormat == IVAS_DEC_BS_MASA_ISM || bsFormat == IVAS_DEC_BS_SBA_ISM )
        {
@@ -3177,7 +3177,7 @@ static ivas_error decodeVoIP(
            }

            /* Write ISM metadata to external file(s) */
            if ( decodedGoodFrame && arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
            if ( decodedGoodFrame && arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
            {
                if ( bsFormat == IVAS_DEC_BS_OBJ || bsFormat == IVAS_DEC_BS_MASA_ISM || bsFormat == IVAS_DEC_BS_SBA_ISM )
                {
@@ -3207,7 +3207,7 @@ static ivas_error decodeVoIP(

                if ( bsFormat == IVAS_DEC_BS_MASA || bsFormat == IVAS_DEC_BS_MASA_ISM )
                {
                    MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                    IVAS_MASA_DECODER_EXT_OUT_META_HANDLE hMasaExtOutMeta;
                    if ( ( error = IVAS_DEC_GetMasaMetadata( hIvasDec, &hMasaExtOutMeta, 1 ) ) != IVAS_ERR_OK )
                    {
                        fprintf( stderr, "\nError in IVAS_DEC_GetMasaMetadata: %s\n", IVAS_DEC_GetErrorMessage( error ) );
@@ -3264,7 +3264,7 @@ static ivas_error decodeVoIP(
    }

    /* Print output metadata file name(s) */
    if ( arg.outputConfig == AUDIO_CONFIG_EXTERNAL )
    if ( arg.outputConfig == IVAS_AUDIO_CONFIG_EXTERNAL )
    {
        if ( bsFormat == IVAS_DEC_BS_OBJ || bsFormat == IVAS_DEC_BS_MASA_ISM || bsFormat == IVAS_DEC_BS_SBA_ISM )
        {
+90 −89

File changed.

Preview size limit exceeded, changes collapsed.

+1 −1
Original line number Diff line number Diff line
@@ -2712,7 +2712,7 @@ ivas_error preview_indices(
                st_ivas->nchan_transport++;
                k--;
            }
            st_ivas->transport_config = AUDIO_CONFIG_EXTERNAL + st_ivas->nchan_transport;
            st_ivas->transport_config = IVAS_AUDIO_CONFIG_EXTERNAL + st_ivas->nchan_transport;

            st_ivas->ism_mode = ivas_ism_mode_select( st_ivas->nchan_transport, total_brate );
            st_ivas->nSCE = st_ivas->nchan_transport;
+3 −3
Original line number Diff line number Diff line
@@ -69,7 +69,7 @@
#define PCM16_TO_FLT_FAC                32768.0f
#define MDFT_NORM_SCALING               ( 1.0f / PCM16_TO_FLT_FAC )
#define MAX_FRAME_COUNTER               200
#define MAX_BITS_PER_FRAME              10240           /* Bits per frame for max. bitrate 512kbps */
#define MAX_BITS_PER_FRAME              10240           /* Bits per frame for max. bitrate 512kbps, == IVAS_MAX_BITS_PER_FRAME */

#define ENC                             0               /* Index for "encoder" */
#define DEC                             1               /* Index for "decoder" */
@@ -621,8 +621,8 @@ enum

#define L_HP20_MEM                          4                      /* HP20 filter memory length */

#define CLDFB_NO_CHANNELS_MAX               60                     /* CLDFB resampling - max number of CLDFB channels */
#define CLDFB_NO_COL_MAX                    16                     /* CLDFB resampling - max number of CLDFB col. */
#define CLDFB_NO_CHANNELS_MAX               60                     /* CLDFB resampling - max number of CLDFB channels, == IVAS_CLDFB_NO_CHANNELS_MAX */
#define CLDFB_NO_COL_MAX                    16                     /* CLDFB resampling - max number of CLDFB col., == IVAS_CLDFB_NO_COL_MAX */
#define CLDFB_NO_COL_MAX_SWITCH             6                      /* CLDFB resampling - max number of CLDFB col. for switching */
#define CLDFB_NO_COL_MAX_SWITCH_BFI         10                     /* CLDFB resampling - max number of CLDFB col. for switching, BFI */
#define CLDFB_OVRLP_MIN_SLOTS               3                      /* CLDFB resampling - minimize processing to minimum required for transition frame ACELP->TCX/HQ */
+45 −46

File changed.

Preview size limit exceeded, changes collapsed.

Loading