Commit cc41a344 authored by TYAGIRIS's avatar TYAGIRIS
Browse files

further debugging changes

parent aebdf673
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -41,15 +41,17 @@

/* ################### Start DEBUGGING switches ######################## */

/*#define DEBUGGING*/                             /* Allows debugging message to be printed out during runtime */
#define DEBUGGING                             /* Allows debugging message to be printed out during runtime */
#ifdef DEBUGGING
#define DEBUG_MODE_INFO                       /* Define to output most important parameters to the subdirectory "res/" */
#define DEBUG_MODE_INFO_TWEAK                 /* Enable command line switch to specify subdirectory for debug info output inside "./res/" */
#define DEBUG_FORCE_MDCT_STEREO_MODE          /* Force stereo mode decision for MDCT stereo: -stereo 3 1 forces L/R coding and -stereo 3 2 forces full M/S coding */
/*#define DEBUG_FORCE_DIR*/                       /* Force modes/parameters by reading from external binary files */
/*#define DBG_WAV_WRITER*/                    /* Enable dbgwrite_wav() function for generating ".wav" files */
#define DEBUG_BYPASS_CORE_CODER
#define DEBUG_SPAR_FX_CODE
//#define DEBUG_BYPASS_CORE_CODER
#define DEBUG_DUMP_CORE_CODER_IN
#define DEBUG_INJECT_CORE_CODER_IN
//#define DEBUG_SPAR_FX_CODE
//#define DEBUG_SPAR_FBMIXER_RE_IM
//#define DEBUG_SPAR_FBMIXER_MDFTOUT
//#define DEBUG_SPAR_FBMIXER_CROSSFADED
+2 −2
Original line number Diff line number Diff line
@@ -364,7 +364,7 @@ int16_t dbgread(
    {
        index = in_count;
        in_fileptr[index] = fopen( filename, "rb" );
#ifdef DEBUG_FORCE_DIR
#if defined DEBUG_FORCE_DIR
        if ( in_fileptr[index] == NULL )
        {
            /* file does not exist or could not be opened -> just return */
+17 −2
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@
#include "ivas_rom_com.h"
#include "wmc_auto.h"
#include "ivas_prot_fx.h"
#ifdef DEBUG_BYPASS_CORE_CODER
#ifdef DEBUGGING
#include "debug.h"
#endif

@@ -83,7 +83,7 @@ void ivas_sba_getTCs_fx(
        }
    }

#ifdef DEBUG_BYPASS_CORE_CODER
#if defined DEBUG_BYPASS_CORE_CODER || defined DEBUG_DUMP_CORE_CODER_IN
    for ( int16_t n = 0; n < st_ivas->nchan_transport; n++ )
    {
        int16_t tmp[L_FRAME48k];
@@ -98,6 +98,21 @@ void ivas_sba_getTCs_fx(
    }
#endif

#ifdef DEBUG_INJECT_CORE_CODER_IN
    for ( int16_t n = 0; n < st_ivas->nchan_transport; n++ )
    {
        int16_t tmp[L_FRAME48k];
        char file_name[100] = { 0 };

        sprintf( file_name, "./res/ivas_core_coder_fl_in_ch_%d.pcm", n );
        dbgread( tmp, sizeof( int16_t ), input_frame, file_name );
        for ( int16_t i = 0; i < input_frame; i++ )
        {
            sba_data[n][i] = (Word32) ( tmp[i] << 11 );
        }
    }
#endif

    return;
}