![]() |
Sayonara Player
|
The EQ_Setting class. Container for Equalizer configurations. More...
#include <EqualizerSetting.h>
Public Types | |
using | ValueArray = std::array< int, 10 > |
Public Member Functions | |
EqualizerSetting (const QString &name=QString()) | |
EqualizerSetting (const QString &name, const ValueArray &values) | |
EqualizerSetting (const EqualizerSetting &other) | |
EqualizerSetting & | operator= (const EqualizerSetting &s) |
bool | operator== (const EqualizerSetting &s) const |
Compares the case insensitive string representation of two settings. More... | |
QString | name () const |
get name of setting More... | |
void | set_name (const QString &name) |
set name of setting More... | |
ValueArray | values () const |
get database values for setting More... | |
int | value (int idx) const |
get specific value for a band idx. if idx is not valid, 0 is returned More... | |
void | set_value (int idx, int val) |
set specific value for band More... | |
void | set_values (const ValueArray &values) |
set all values for a specific index. If there are more than 10 values, list is stripped. If there are less, the list is filled with zeros More... | |
bool | is_default () const |
append a value. If there are already more than 10 values, nothing happens More... | |
bool | is_default_name () const |
checks, if the preset name belongs to a default preset More... | |
bool | loadFromString (const QString &str) override |
converts a string to a EQ_Setting. If not possible a default constructed EQ_Setting is returned More... | |
QString | toString () const override |
converts EQ_Setting to string More... | |
Static Public Member Functions | |
static QList< EqualizerSetting > | get_defaults () |
get default settings More... | |
static ValueArray | get_default_values (const QString &name) |
get default values for a specific preset. If the preset does not have default values, an empty list is returned More... | |
static bool | is_default_name (const QString &name) |
static convenience function for is_default_name() More... | |
The EQ_Setting class. Container for Equalizer configurations.
|
static |
get default values for a specific preset. If the preset does not have default values, an empty list is returned
name | preset name |
|
static |
get default settings
bool EqualizerSetting::is_default | ( | ) | const |
append a value. If there are already more than 10 values, nothing happens
valchecks,if | preset is default preset |
bool EqualizerSetting::is_default_name | ( | ) | const |
checks, if the preset name belongs to a default preset
|
static |
|
overridevirtual |
converts a string to a EQ_Setting. If not possible a default constructed EQ_Setting is returned
str |
Implements SettingConvertible.
QString EqualizerSetting::name | ( | ) | const |
get name of setting
bool EqualizerSetting::operator== | ( | const EqualizerSetting & | s | ) | const |
Compares the case insensitive string representation of two settings.
s | other preset |
void EqualizerSetting::set_name | ( | const QString & | name | ) |
set name of setting
name |
void EqualizerSetting::set_value | ( | int | idx, |
int | val | ||
) |
set specific value for band
idx | band index |
val | database formatted value |
void EqualizerSetting::set_values | ( | const ValueArray & | values | ) |
set all values for a specific index. If there are more than 10 values, list is stripped. If there are less, the list is filled with zeros
values |
|
overridevirtual |
int EqualizerSetting::value | ( | int | idx | ) | const |
get specific value for a band idx. if idx is not valid, 0 is returned
idx | band index |
ValueArray EqualizerSetting::values | ( | ) | const |
get database values for setting