Skip to content

Commit

Permalink
Fix bug where integer division was used instead of floating point
Browse files Browse the repository at this point in the history
This caused empty output.
Thanks to Nicu Badescu for the persistent bug report
  • Loading branch information
jeremysalwen committed Jul 31, 2014
1 parent fa43aa8 commit 7ff733d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kn0ck0ut6.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ void AKnockout::do_rebuild(long numSampsToProcess, long fftFrameSize, long osamp
long stepSize = fftFrameSize/osamp;
//float dOversampbytwopi = osamp/(PI*2);
//float freqPerBin = sampleRate/fftFrameSize;
float dOutfactor = 1/(fftFrameSize2*osamp);
float dOutfactor = 1.0f/(fftFrameSize2*osamp);
fDecayRate=(fDecayRate>0)*(4.00001-(fDecayRate*fDecayRate*4));

//float expct = 2.*PI*(double)stepSize/(double)fftFrameSize;
Expand Down

0 comments on commit 7ff733d

Please sign in to comment.