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

◆ Backbeat() [1/3]

fl::audio::detector::Backbeat::Backbeat ( shared_ptr< Beat > beatDetector)
explicit

Construct with shared Beat.

Definition at line 10 of file backbeat.cpp.hpp.

11 : mBeatDetector(beatDetector)
12 , mDownbeatDetector(nullptr)
13 , mOwnsBeatDetector(false)
15 , mBackbeatDetected(false)
17 , mConfidence(0.0f)
18 , mCurrentStrength(0.0f)
19 , mBackbeatRatio(1.0f)
21 , mBassThreshold(1.2f)
22 , mMidThreshold(1.3f)
23 , mHighThreshold(1.1f)
24 , mBackbeatMask(0x0A) // Bits 1 and 3 = beats 2 and 4 in 4/4
25 , mAdaptive(true)
26 , mCurrentBeat(1)
28 , mPreviousWasBeat(false)
29 , mBackbeatMean(1.0f)
30 , mNonBackbeatMean(0.8f)
31 , mAdaptiveThreshold(1.0f)
32 , mProfileAlpha(0.1f)
33{
34 mPreviousAccent = {0.0f, 0.0f, 0.0f, 0.0f};
36 for (size i = 0; i < SPECTRAL_PROFILE_SIZE; i++) {
37 mBackbeatSpectralProfile.push_back(0.0f);
38 }
39}
shared_ptr< Beat > mBeatDetector
Definition backbeat.h:122
MultibandAccent mPreviousAccent
Definition backbeat.h:148
vector< float > mBackbeatSpectralProfile
Definition backbeat.h:159
shared_ptr< Downbeat > mDownbeatDetector
Definition backbeat.h:123
static constexpr size SPECTRAL_PROFILE_SIZE
Definition backbeat.h:160

References mAdaptive, mAdaptiveThreshold, mBackbeatDetected, mBackbeatMask, mBackbeatMean, mBackbeatRatio, mBackbeatSpectralProfile, mBassThreshold, mBeatDetector, mBeatsPerMeasure, mConfidence, mConfidenceThreshold, mCurrentBeat, mCurrentStrength, mDownbeatDetector, mHighThreshold, mLastBackbeatNumber, mMidThreshold, mNonBackbeatMean, mOwnsBeatDetector, mOwnsDownbeatDetector, mPreviousAccent, mPreviousWasBeat, mProfileAlpha, and SPECTRAL_PROFILE_SIZE.

Referenced by Backbeat(), Backbeat(), and update().

+ Here is the caller graph for this function: