1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 15:57:45 +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:
kleines Filmröllchen 2021-10-12 01:15:12 +02:00 committed by Andreas Kling
parent 98058f7efe
commit e7d84da3da
3 changed files with 18 additions and 9 deletions

View file

@ -11,9 +11,9 @@ namespace LibDSP::Effects {
Delay::Delay(NonnullRefPtr<Transport> transport)
: EffectProcessor(move(transport))
, m_delay_decay("Decay"sv, 0.01, 0.99, 0.33)
, m_delay_time("Delay Time"sv, 3, 2000, 900)
, m_dry_gain("Dry"sv, 0, 1, 0.9)
, m_delay_decay("Decay"sv, 0.01, 0.99, 0.33, Logarithmic::No)
, m_delay_time("Delay Time"sv, 3, 2000, 900, Logarithmic::Yes)
, m_dry_gain("Dry"sv, 0, 1, 0.9, Logarithmic::No)
{
m_parameters.append(m_delay_decay);