FastLED 3.9.15
Loading...
Searching...
No Matches

◆ normalize()

float fl::audio::NoiseFloorTracker::normalize ( float level) const

Normalize signal by removing noise floor.

Parameters
levelSignal level to normalize
Returns
Normalized level (clamped to >= 0)

Definition at line 65 of file noise_floor_tracker.cpp.hpp.

65 {
66 // Remove noise floor from signal, clamped to non-negative
67 const float normalized = level - mCurrentFloor;
68 return fl::max(0.0f, normalized);
69}
float mCurrentFloor
Current noise floor estimate.
constexpr common_type_t< T, U > max(T a, U b) FL_NOEXCEPT
Definition math.h:75

References fl::max(), and mCurrentFloor.

+ Here is the call graph for this function: