Commit b4d6bd84 authored by vaclav's avatar vaclav
Browse files

Merge branch '1081-decoding-to-binaural_split_pcm-sanity-check' into 'main'

Resolve "Decoding to BINAURAL_SPLIT_PCM sanity check"

See merge request !1537
parents 8423233c d2446825
Loading
Loading
Loading
Loading
Loading
+17 −0
Original line number Diff line number Diff line
@@ -1704,6 +1704,15 @@ static bool parseCmdlIVAS_dec(
            usage_dec();
            return false;
        }

#ifdef FIX_1081_BINAURAL_SPLIT_PCM_SANITY_CHECK
        if ( arg->outputMdFilename != NULL && arg->outputConfig != IVAS_AUDIO_CONFIG_BINAURAL_SPLIT_PCM )
        {
            fprintf( stderr, "Error: Output split rendering metadata file is supported for BINAURAL_SPLIT_PCM output config. only\n\n" );
            usage_dec();
            return false;
        }
#endif
    }
    else
    {
@@ -1990,6 +1999,14 @@ static ivas_error initOnFirstGoodFrame(
        }
        else
        {
#ifdef FIX_1081_BINAURAL_SPLIT_PCM_SANITY_CHECK
            if ( arg.outputMdFilename == NULL )
            {
                fprintf( stderr, "\nOutput split rendering metadata file not specified\n" );
                return IVAS_ERR_INVALID_SPLIT_REND_CONFIG;
            }
#endif

            if ( ( error = split_rend_writer_open( splitRendWriter, arg.outputMdFilename, delayNumSamples_temp[0], delayTimeScale_temp, splitRendCodec, poseCorrection, splitRendCodecFrameSizeMs ) ) != IVAS_ERR_OK )
            {
                fprintf( stderr, "\nUnable to open output split rendering metadata file %s\n", arg.outputWavFilename );
+1 −1
Original line number Diff line number Diff line
@@ -159,7 +159,7 @@
#define FIX_NUM_SUBFRAME_UPDATE

#define FIX_1053_REVERB_RECONFIGURATION                 /* Philips: issue 1053: fix for dynamic switching of acoustic environment */

#define FIX_1081_BINAURAL_SPLIT_PCM_SANITY_CHECK        /* VA: issue 1081: correct error print-out when BINAURAL_SPLIT_PCM is requested */

/* #################### End BE switches ################################## */