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

◆ isValidIBI()

bool fl::audio::detector::MusicalBeat::isValidIBI ( float ibi) const
private

Check if IBI is within valid BPM range.

Parameters
ibiInter-beat interval in seconds
Returns
True if IBI corresponds to valid BPM (minBPM-maxBPM)

Definition at line 207 of file musical_beat_detector.cpp.hpp.

207 {
208 if (ibi <= 0.0f) {
209 return false;
210 }
211
212 // Convert IBI to BPM
213 float bpm = 60.0f / ibi;
214
215 // Check if BPM is within valid range
216 return (bpm >= mConfig.minBPM) && (bpm <= mConfig.maxBPM);
217}
void bpm()

References bpm(), and mConfig.

Referenced by processSample(), and validateBeat().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: