Skip to content

Commit

Permalink
Fix pitch shifter 0 division with glide
Browse files Browse the repository at this point in the history
  • Loading branch information
LostRobotMusic authored Jun 26, 2024
1 parent 6634cec commit cd379e8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ bool GranularPitchShifterEffect::processAudioBuffer(sampleFrame* buf, const fpp_
if (glide != m_oldGlide)
{
m_oldGlide = glide;
m_glideCoef = std::exp(-1 / (glide * m_sampleRate));
m_glideCoef = glide >= 0 ? std::exp(-1 / (glide * m_sampleRate)) : 1;
}

const float shapeK = cosWindowApproxK(shape);
Expand Down

0 comments on commit cd379e8

Please sign in to comment.