Skip to content

Commit

Permalink
renamed to gOutBuffer
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremysalwen committed Jun 3, 2011
1 parent e97162c commit 867e953
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions kn0ck0ut6.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ AKnockout::AKnockout(double rate) : Plugin<AKnockout>(p_n_ports)
{
sampleRate=rate;
gInFIFO = new float [MAX_FRAME_LENGTH];
gOutFIFO = new float [MAX_FRAME_LENGTH];
gOutBuffer = new float [MAX_FRAME_LENGTH];
gFFTworksp = (fftwf_complex*)fftwf_malloc(sizeof(fftwf_complex) * MAX_FRAME_LENGTH);
gOutputBuffer=new float [2*MAX_FRAME_LENGTH];
gOutputAccum = new float [2*MAX_FRAME_LENGTH];
Expand Down Expand Up @@ -70,7 +70,7 @@ AKnockout::AKnockout(double rate) : Plugin<AKnockout>(p_n_ports)
AKnockout::~AKnockout() // delete buffers in destructor
{
delete[] gInFIFO;
delete[] gOutFIFO;
delete[] gOutBuffer;
fftwf_free(gFFTworksp);
delete[] gOutputAccum;
delete[] gOutputBuffer;
Expand All @@ -89,7 +89,7 @@ AKnockout::~AKnockout() // delete buffers in destructor
void AKnockout::suspend ()
{
memset(gInFIFO, 0, MAX_FRAME_LENGTH*sizeof(float));
memset(gOutFIFO, 0, MAX_FRAME_LENGTH*sizeof(float));
memset(gOutBuffer, 0, MAX_FRAME_LENGTH*sizeof(float));
memset(gFFTworksp, 0, 2*MAX_FRAME_LENGTH*sizeof(float));
memset(gOutputAccum, 0, 2*MAX_FRAME_LENGTH*sizeof(float));
memset(gOutputBuffer, 0, 2*MAX_FRAME_LENGTH*sizeof(float));
Expand Down Expand Up @@ -145,7 +145,7 @@ void AKnockout::do_rebuild(long numSampsToProcess, long fftFrameSize, long osamp
/* As long as we have not yet collected enough data just read in */
gInFIFO[gRover] = indata[i];
gInFIFO2[gRover] = (indata2[i]-(indata[i]*centreExtract)); // R input gain factor here
outdata[i] = gOutFIFO[gRover-inFifoLatency]; // output, gain control here
outdata[i] = gOutBuffer[gRover-inFifoLatency]; // output, gain control here

gRover++;

Expand Down Expand Up @@ -266,7 +266,7 @@ void AKnockout::do_rebuild(long numSampsToProcess, long fftFrameSize, long osamp
}

/* transfer output accum to output buffer */
memmove (gOutFIFO, gOutputAccum, stepSize*sizeof(float));
memmove (gOutBuffer, gOutputAccum, stepSize*sizeof(float));

/* shift accumulator */
memmove(gOutputAccum, gOutputAccum+stepSize, fftFrameSize*sizeof(float));
Expand Down
4 changes: 2 additions & 2 deletions kn0ck0ut6.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ class AKnockout:public Plugin<AKnockout> {
void do_rebuild(long numSampsToProcess, long fftFrameSize, long osamp, float sampleRate, float *indata, float *indata2, float *outdata, long gInit, float fDecayRate, int iBlur, int loCut, int HiCut, int centreExtract);
void makelookup(int fftFrameSize);

float* gInFIFO;
float* gOutFIFO;
float* gInFIFO;
float* gOutBuffer;
float* gOutputAccum;
float* gOutputBuffer;
float* gAnaFreq;
Expand Down

0 comments on commit 867e953

Please sign in to comment.