mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 10:08:10 +00:00
LibDSP: Allow ProcessorRangeParameter to specify if it's a log value
This doesn't affect the parameter's own behavior but is part of the parameter meta-data, just as the name. If a parameter is logarithmic, UI elements should represent it with an interface that scales logarithmically.
This commit is contained in:
parent
98058f7efe
commit
e7d84da3da
3 changed files with 18 additions and 9 deletions
|
@ -17,10 +17,10 @@ namespace LibDSP::Synthesizers {
|
|||
Classic::Classic(NonnullRefPtr<Transport> transport)
|
||||
: LibDSP::SynthesizerProcessor(transport)
|
||||
, m_waveform("Waveform"sv, Waveform::Saw)
|
||||
, m_attack("Attack"sv, 0, 2000, 5)
|
||||
, m_decay("Decay"sv, 0, 20'000, 80)
|
||||
, m_sustain("Sustain"sv, 0, 1, 0.725)
|
||||
, m_release("Release", 0, 6'000, 120)
|
||||
, m_attack("Attack"sv, 0.01, 2000, 5, Logarithmic::Yes)
|
||||
, m_decay("Decay"sv, 0.01, 20'000, 80, Logarithmic::Yes)
|
||||
, m_sustain("Sustain"sv, 0.001, 1, 0.725, Logarithmic::No)
|
||||
, m_release("Release", 0.01, 6'000, 120, Logarithmic::Yes)
|
||||
{
|
||||
m_parameters.append(m_waveform);
|
||||
m_parameters.append(m_attack);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue