#include <MIDI_Inputs/InterfaceMIDIInputElements.hpp>
An abstract interface for VU meters.
To allow for both floating point values and integers, all values are integers under the hood.
Using floats instead integers would be a strange choice as LED bar VU meters have discrete levels.
Continuous "analog" VU meters can use or override the getFloatValue() method.
Definition at line 87 of file InterfaceMIDIInputElements.hpp.
Inheritance diagram for IVU:
Collaboration diagram for IVU:Detecting changes | |
| bool | getDirty () const |
| Check if the value was updated since the last time the dirty flag was cleared. More... | |
| void | clearDirty () |
| Clear the dirty flag. More... | |
Public Member Functions | |
| IVU (uint8_t max, bool alwaysDirty=false) | |
| virtual uint8_t | getValue ()=0 |
| Return the VU meter value as an integer. More... | |
| virtual bool | getOverload ()=0 |
| Return the overload status. More... | |
| virtual float | getFloatValue () |
| Get the VU meter value as a floating point number. More... | |
| uint8_t | getMax () const |
| Get the maximum value that this VU meter can return. More... | |
Protected Attributes | |
| uint8_t | max |
| bool | alwaysDirty |
| bool | dirty = true |
|
inline |
Definition at line 89 of file InterfaceMIDIInputElements.hpp.
|
inline |
Check if the value was updated since the last time the dirty flag was cleared.
Definition at line 97 of file InterfaceMIDIInputElements.hpp.
|
inline |
Clear the dirty flag.
Definition at line 99 of file InterfaceMIDIInputElements.hpp.
|
pure virtual |
Return the VU meter value as an integer.
Implemented in AudioVU, VU, and VU< BankSize >.
|
pure virtual |
Return the overload status.
Implemented in AudioVU, VU, and VU< BankSize >.
|
inlinevirtual |
Get the VU meter value as a floating point number.
Reimplemented in AudioVU, and VU< BankSize >.
Definition at line 108 of file InterfaceMIDIInputElements.hpp.
|
inline |
Get the maximum value that this VU meter can return.
Definition at line 110 of file InterfaceMIDIInputElements.hpp.
|
protected |
Definition at line 113 of file InterfaceMIDIInputElements.hpp.
|
protected |
Definition at line 114 of file InterfaceMIDIInputElements.hpp.
|
protected |
Definition at line 115 of file InterfaceMIDIInputElements.hpp.