Audacity 3.2.0
|
#include <EffectInterface.h>
Classes | |
class | Message |
Type of messages to send from main thread to processing. More... | |
Public Member Functions | |
virtual | ~EffectSettingsAccess () |
virtual const EffectSettings & | Get ()=0 |
virtual void | Set (EffectSettings &&settings, std::unique_ptr< Message > pMessage=nullptr)=0 |
virtual void | Set (std::unique_ptr< Message > pMessage=nullptr)=0 |
Message-only overload of Set(). In future, this should be the only one. More... | |
virtual void | Flush ()=0 |
Make the last Set changes "persistent" in underlying storage. More... | |
virtual bool | IsSameAs (const EffectSettingsAccess &other) const =0 |
template<typename Function > | |
void | ModifySettings (Function &&function) |
Do a correct read-modify-write of settings. More... | |
Interface for accessing an EffectSettings that may change asynchronously in another thread; to be used in the main thread, only.
Updates are communicated atomically both ways. The address of Get() should not be relied on as unchanging between calls.
Definition at line 152 of file EffectInterface.h.
|
virtualdefault |
|
pure virtual |
Make the last Set
changes "persistent" in underlying storage.
Implemented in SimpleEffectSettingsAccess, RealtimeEffectState::Access, and anonymous_namespace{EffectUI.cpp}::EffectSettingsAccessTee.
Referenced by VSTEditor::Flush(), VSTEditor::OnClose(), VST3Editor::OnClose(), LV2Editor::OnIdle(), VSTEditor::OnIdle(), and VST3Editor::UpdateUI().
|
pure virtual |
Implemented in SimpleEffectSettingsAccess, RealtimeEffectState::Access, and anonymous_namespace{EffectUI.cpp}::EffectSettingsAccessTee.
Referenced by AudioUnitEditor::AudioUnitEditor(), LV2Editor::BuildPlain(), VSTEditor::BuildPlain(), EffectPreview(), anonymous_namespace{DynamicRangeProcessorEditor.cpp}::GetSettings(), EffectBassTreble::MakeEditor(), EffectCompressor::MakeEditor(), EffectDistortion::MakeEditor(), EffectDtmf::MakeEditor(), EffectEcho::MakeEditor(), EffectLimiter::MakeEditor(), EffectPhaser::MakeEditor(), EffectReverb::MakeEditor(), EffectWahwah::MakeEditor(), VSTEditor::NotifyParameterChanged(), LV2Editor::OnIdle(), EffectNoise::PopulateOrExchange(), EffectSilence::PopulateOrExchange(), EffectToneGen::PopulateOrExchange(), LV2Effect::PopulateUI(), LadspaEditor::PopulateUI(), LadspaEditor::RefreshControls(), DynamicRangeProcessorEditor::UpdateUI(), AudioUnitEditor::UpdateUI(), LV2Editor::UpdateUI(), VST3Editor::VST3Editor(), and VSTEditor::VSTEditor().
|
pure virtual |
Implemented in SimpleEffectSettingsAccess, RealtimeEffectState::Access, and anonymous_namespace{EffectUI.cpp}::EffectSettingsAccessTee.
|
inline |
Do a correct read-modify-write of settings.
function | takes EffectSettings & and its return is a unique pointer to Message, possibly null. If it throws an exception, then the settings will not be updated. Thus, a strong exception safety guarantee. |
Definition at line 211 of file EffectInterface.h.
References BasicUI::Get(), and settings().
Referenced by EffectPreview(), LV2Editor::OnChoice(), VST3Editor::OnClose(), VST3Editor::OnIdle(), AudioUnitEditor::OnIdle(), VSTEditor::OnIdle(), LV2Editor::OnSlider(), LV2Editor::OnText(), LV2Editor::OnToggle(), LV2Editor::OnTrigger(), LV2Editor::suil_port_write(), VST3Editor::UpdateUI(), DynamicRangeProcessorEditor::ValidateUI(), AudioUnitEditor::ValidateUI(), EffectDistortion::Editor::ValidateUI(), LadspaEditor::ValidateUI(), LV2Editor::ValidateUI(), EffectReverb::Editor::ValidateUI(), anonymous_namespace{StatefulEffectUIServices.cpp}::DefaultEffectEditor::ValidateUI(), VSTEditor::ValidateUI(), VST3Editor::ValidateUI(), EffectWahwah::Editor::ValidateUI(), and VSTEditor::VSTEditor().
|
pure virtual |
Implemented in SimpleEffectSettingsAccess, RealtimeEffectState::Access, and anonymous_namespace{EffectUI.cpp}::EffectSettingsAccessTee.
Referenced by VSTEditor::Automate(), AudioUnitEditor::EventListener(), and VSTEditor::OnSlider().
|
pure virtual |
Message-only overload of Set(). In future, this should be the only one.
Implemented in SimpleEffectSettingsAccess, RealtimeEffectState::Access, and anonymous_namespace{EffectUI.cpp}::EffectSettingsAccessTee.