Skip to content

Commit

Permalink
math problems
Browse files Browse the repository at this point in the history
  • Loading branch information
Andreya-Autumn committed Oct 15, 2024
1 parent 1e49dff commit f2525e9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/sst/voice-effects/generator/TiltNoise.h
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ template <typename VFXConfig> struct TiltNoise : core::VoiceEffectTemplateBase<V

void setCoeffs()
{
float slope = std::clamp(this->getFloatParam(fpTilt), -6, 6) / 2;
float slope = clamp(this->getFloatParam(fpTilt), -6, 6) / 2;
float posGain = this->dbToLinear(slope);
float negGain = this->dbToLinear(-1 * slope);
float res = .07f;
Expand Down
2 changes: 1 addition & 1 deletion include/sst/voice-effects/modulation/NoiseAM.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ template <typename VFXConfig> struct NoiseAM : core::VoiceEffectTemplateBase<VFX

void setCoeffs()
{
float slope = std::clamp(this->getFloatParam(fpTilt), -6, 6) / 2;
float slope = clamp(this->getFloatParam(fpTilt), -6, 6) / 2;
float posGain = this->dbToLinear(slope);
float negGain = this->dbToLinear(-1 * slope);
float res = .07f;
Expand Down
2 changes: 1 addition & 1 deletion tests/create-voice-effect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ TEST_CASE("Can Create Voice FX")
{
VTester<sst::voice_effects::generator::TiltNoise<VTestConfig>>::TestVFX();
}
SECTION("Phaser") { VTester<sst::voice_effects::modulation::NoiseAM<VTestConfig>>::TestVFX(); }
SECTION("Noise AM") { VTester<sst::voice_effects::modulation::NoiseAM<VTestConfig>>::TestVFX(); }
SECTION("VolumeAndPan")
{
VTester<sst::voice_effects::utilities::VolumeAndPan<VTestConfig>>::TestVFX();
Expand Down

0 comments on commit f2525e9

Please sign in to comment.