From 6fc525c6c7b7d324b8f1b302fd4749e8c9af8ce8 Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Thu, 7 Jun 2007 18:13:22 +0000 Subject: [PATCH] Make DEBUG_TRACE be the define for libresample to print debug info to the screen instead of DEBUG git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5281 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- libs/libresample/src/resample.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/libs/libresample/src/resample.c b/libs/libresample/src/resample.c index b33422e3e0..26b3daeb95 100644 --- a/libs/libresample/src/resample.c +++ b/libs/libresample/src/resample.c @@ -87,7 +87,7 @@ void *resample_open(int highQuality, double minFactor, double maxFactor) /* Just exit if we get invalid factors */ if (minFactor <= 0.0 || maxFactor <= 0.0 || maxFactor < minFactor) { -#ifdef DEBUG +#ifdef DEBUG_TRACE fprintf(stderr, "libresample: " "minFactor and maxFactor must be positive real numbers,\n" @@ -187,7 +187,7 @@ int resample_process(void *handle, int Nx; int i, len; -#ifdef DEBUG +#ifdef DEBUG_TRACE fprintf(stderr, "resample_process: in=%d, out=%d lastFlag=%d\n", inBufferLen, outBufferLen, lastFlag); #endif @@ -197,7 +197,7 @@ int resample_process(void *handle, outSampleCount = 0; if (factor < hp->minFactor || factor > hp->maxFactor) { -#ifdef DEBUG +#ifdef DEBUG_TRACE fprintf(stderr, "libresample: factor %f is not between " "minFactor=%f and maxFactor=%f", @@ -232,7 +232,7 @@ int resample_process(void *handle, /* This is the maximum number of samples we can process per loop iteration */ - #ifdef DEBUG + #ifdef DEBUG_TRACE printf("XSize: %d Xoff: %d Xread: %d Xp: %d lastFlag: %d\n", hp->XSize, hp->Xoff, hp->Xread, hp->Xp, lastFlag); #endif @@ -260,7 +260,7 @@ int resample_process(void *handle, else Nx = hp->Xread - 2 * hp->Xoff; - #ifdef DEBUG + #ifdef DEBUG_TRACE fprintf(stderr, "new len=%d Nx=%d\n", len, Nx); #endif @@ -277,7 +277,7 @@ int resample_process(void *handle, Nwing, LpScl, Imp, ImpD, interpFilt); } - #ifdef DEBUG + #ifdef DEBUG_TRACE printf("Nout: %d\n", Nout); #endif @@ -297,7 +297,7 @@ int resample_process(void *handle, for (i=0; iX[i] = hp->X[i + (hp->Xp - hp->Xoff)]; - #ifdef DEBUG + #ifdef DEBUG_TRACE printf("New Xread=%d\n", Nreuse); #endif @@ -306,7 +306,7 @@ int resample_process(void *handle, /* Check to see if output buff overflowed (shouldn't happen!) */ if (Nout > hp->YSize) { - #ifdef DEBUG + #ifdef DEBUG_TRACE printf("Nout: %d YSize: %d\n", Nout, hp->YSize); #endif fprintf(stderr, "libresample: Output array overflow!\n");