Class daisy::CpuLoadMeter¶
ClassList > daisy > CpuLoadMeter
Public Functions¶
Type | Name |
---|---|
CpuLoadMeter () |
|
float | GetAvgCpuLoad () const |
float | GetMaxCpuLoad () const |
float | GetMinCpuLoad () const |
void | Init (float sampleRateInHz, int blockSizeInSamples, float smoothingFilterCutoffHz=1.0f) |
void | OnBlockEnd () |
void | OnBlockStart () |
void | Reset () |
Public Functions Documentation¶
function CpuLoadMeter [½]¶
function GetAvgCpuLoad¶
Returns the smoothed average CPU load in the range 0..1
function GetMaxCpuLoad¶
Returns the maximum CPU load observed since the last call to Reset().
function GetMinCpuLoad¶
Returns the minimun CPU load observed since the last call to Reset().
function Init¶
inline void daisy::CpuLoadMeter::Init (
float sampleRateInHz,
int blockSizeInSamples,
float smoothingFilterCutoffHz=1.0f
)
Initializes the CpuLoadMeter for a particular sample rate and block size.
Parameters:
sampleRateInHz
The sample rate in HzblockSizeInSamples
The block size in samplessmoothingFilterCutoffHz
The cutoff frequency of the smoothing filter that's used to create the average CPU load reading.
function OnBlockEnd¶
Call this at the end of your audio callback
function OnBlockStart¶
Call this at the beginning of your audio callback
function Reset¶
Resets the minimun, maximum and average load readings.
The documentation for this class was generated from the following file external-docs/libDaisy/src/util/CpuLoadMeter.h