Commit 9dc87504 authored by vaclav's avatar vaclav
Browse files

Issue 355: remove obsolete "-force_subframe_bin" command-line option; under...

Issue 355: remove obsolete "-force_subframe_bin" command-line option; under REMOVE_FORCE_SUBFRAME_BIN
parent f384a864
Loading
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -105,7 +105,9 @@ typedef struct
    char *renderConfigFilename;

#ifdef DEBUGGING
#ifndef REMOVE_FORCE_SUBFRAME_BIN
    bool forceSubframeBinauralization;
#endif
    IVAS_DEC_FORCED_REND_MODE forcedRendMode;
#ifdef DEBUG_FOA_AGC
    FILE *agcBitstream; /* temporary */
@@ -271,10 +273,14 @@ int main(
     * Configure the decoder
     *------------------------------------------------------------------------------------------*/

#ifdef REMOVE_FORCE_SUBFRAME_BIN
    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputFormat, arg.customLsOutputEnabled, arg.hrtfReaderEnabled, arg.enableHeadRotation ) ) != IVAS_ERR_OK )
#else
#ifdef DEBUGGING
    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputFormat, arg.customLsOutputEnabled, arg.hrtfReaderEnabled, arg.enableHeadRotation, arg.forceSubframeBinauralization ) ) != IVAS_ERR_OK )
#else
    if ( ( error = IVAS_DEC_Configure( hIvasDec, arg.output_Fs, arg.outputFormat, arg.customLsOutputEnabled, arg.hrtfReaderEnabled, arg.enableHeadRotation ) ) != IVAS_ERR_OK )
#endif
#endif
    {
        fprintf( stderr, "\nConfigure failed: %s\n\n", IVAS_DEC_GetErrorMessage( error ) );
@@ -667,7 +673,9 @@ static bool parseCmdlIVAS_dec(
    float ftmp;

    arg->forcedRendMode = IVAS_DEC_FORCE_REND_UNFORCED;
#ifndef REMOVE_FORCE_SUBFRAME_BIN
    arg->forceSubframeBinauralization = false;
#endif
#ifdef DEBUG_FOA_AGC
    arg->agcBitstream = NULL;
#endif
@@ -819,11 +827,13 @@ static bool parseCmdlIVAS_dec(
                i++;
            }
        }
#ifndef REMOVE_FORCE_SUBFRAME_BIN
        else if ( strcmp( argv_to_upper, "-FORCE_SUBFRAME_BIN" ) == 0 ) /* Force binauralization to subframe (5 ms) resolution */
        {
            arg->forceSubframeBinauralization = true;
            i++;
        }
#endif
#ifdef DEBUG_MODE_INFO
#ifdef DEBUG_MODE_INFO_TWEAK
        /*-----------------------------------------------------------------*
@@ -1073,8 +1083,10 @@ static void usage_dec( void )
    fprintf( stdout, "-T File             : Head rotation specified by external trajectory File\n" );
    fprintf( stdout, "-hrtf File          : HRTF filter File used in BINAURAL output configuration\n" );
#ifdef DEBUGGING
#ifndef REMOVE_FORCE_SUBFRAME_BIN
    fprintf( stdout, "-force_subframe_bin : Forces parametric binauralizer code to use 5 ms time resolution even when\n" );
    fprintf( stdout, "                      output time resolution is larger.\n" );
#endif
    fprintf( stdout, "-FEC X              : Insert frame erasures, X = 0-10 is the percentage\n" );
    fprintf( stdout, "                      of erased frames, or X may be the name of binary file or \n" );
    fprintf( stdout, "                      file with G192 headers indicating GOOD FRAME or BAD FRAME\n" );
+4 −0
Original line number Diff line number Diff line
@@ -148,6 +148,8 @@
#define FIX_347_DTX_CRASH                               /* FhG: Fix crash that can happen with DTX */
#define DISABLE_RES_CHANNELS_MCT                        /* decode only W and residual for Y when outputting to stereo */
#define FIX_107_5MS_SUBFRAME_RENDERING
#define REMOVE_FORCE_SUBFRAME_BIN                       /* Issue 355: remove obsolete "-force_subframe_bin" command-line option. */

#define PARAM_ISM_DTX_CNG                               /* FhG: contribution 9 - DTX-CNG for ParamISM */

#define FIX_331_SBA_HBR_HOA_FIXES                       /* DLB: issue 331 - fix addressing low frequency stuttering with HOA inputs at high bitrates */
@@ -158,6 +160,8 @@
#define SMOOTH_WITH_TRANS_DET
#endif



/* ################## End DEVELOPMENT switches ######################### */
/* clang-format on */
#endif
+2 −1
Original line number Diff line number Diff line
@@ -2071,6 +2071,7 @@ static ivas_error doSanityChecks_IVAS(
        }
    }

#ifndef REMOVE_FORCE_SUBFRAME_BIN
#ifdef DEBUGGING
    if ( st_ivas->hDecoderConfig->forceSubframeBinauralization )
    {
@@ -2095,6 +2096,6 @@ static ivas_error doSanityChecks_IVAS(
        return IVAS_ERROR( IVAS_ERR_INVALID_FORCE_MODE, "Incorrect debug configuration: Cannot force CLDFB renderer in combination with TD renderer HRTF file" );
    }
#endif

#endif
    return IVAS_ERR_OK;
}
+3 −1
Original line number Diff line number Diff line
@@ -1133,7 +1133,9 @@ typedef struct decoder_config_structure

    /* temp. development parameters */
#ifdef DEBUGGING
#ifndef REMOVE_FORCE_SUBFRAME_BIN
    int16_t forceSubframeBinauralization; /* Flag for forcing Parametric binauralizer to subframe mode */
#endif
    int16_t force_rend; /* forced TD/CLDFB binaural renderer (for ISM and MC) */
#endif

+6 −0
Original line number Diff line number Diff line
@@ -223,8 +223,10 @@ static void init_decoder_config(
    hDecoderConfig->Opt_LsCustom = 0;
    hDecoderConfig->Opt_HRTF_binary = 0;
    hDecoderConfig->Opt_Headrotation = 0;
#ifndef REMOVE_FORCE_SUBFRAME_BIN
#ifdef DEBUGGING
    hDecoderConfig->forceSubframeBinauralization = 0;
#endif
#endif
    hDecoderConfig->orientation_tracking = orientation_tracking;
    hDecoderConfig->no_diegetic_pan = no_diegetic_pan;
@@ -390,10 +392,12 @@ ivas_error IVAS_DEC_Configure(
    const int16_t customLsOutputEnabled,      /* i  : enable custom loudspeaker setup handle     */
    const int16_t hrtfReaderEnabled,          /* i  : enable HRTF binary file input              */
    const int16_t enableHeadRotation          /* i  : enable head rotation for binaural output   */
#ifndef REMOVE_FORCE_SUBFRAME_BIN
#ifdef DEBUGGING
    ,
    const int16_t forceSubframeBinauralization /* i  : enable subframe binauralization             */
#endif
#endif
)
{
    Decoder_Struct *st_ivas;
@@ -439,8 +443,10 @@ ivas_error IVAS_DEC_Configure(
        hDecoderConfig->nchan_out = audioCfg2channels( hDecoderConfig->output_config );
    }

#ifndef REMOVE_FORCE_SUBFRAME_BIN
#ifdef DEBUGGING
    hDecoderConfig->forceSubframeBinauralization = forceSubframeBinauralization;
#endif
#endif
    hDecoderConfig->Opt_LsCustom = customLsOutputEnabled;
    hDecoderConfig->Opt_Headrotation = enableHeadRotation;
Loading