Audacity 3.2.0
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | List of all members
EqualizationParameters Struct Reference

Parameters of the Equalization effects that persist in configuration files. More...

#include <EqualizationParameters.h>

Inheritance diagram for EqualizationParameters:
[legend]
Collaboration diagram for EqualizationParameters:
[legend]

Public Types

enum  kInterpolations { kBspline , kCosine , kCubic , nInterpolations }
 

Public Member Functions

 EqualizationParameters (const EffectSettingsManager &manager)
 
void LoadDefaults (int options)
 
void SaveConfig () const
 
bool IsLinear () const
 

Public Attributes

const EffectSettingsManagermSettingsManager
 
wxString mCurveName
 
float mdBMin
 
float mdBMax
 
size_t mM
 
int mInterp
 
bool mDrawMode
 
bool mDrawGrid
 
bool mLin
 

Static Public Attributes

static const EnumValueSymbol kInterpStrings [nInterpolations]
 
static constexpr EffectParameter FilterLength
 
static constexpr EffectParameter CurveName
 
static constexpr EffectParameter InterpLin
 
static constexpr EnumParameter InterpMeth
 
static constexpr EffectParameter DrawMode
 
static constexpr EffectParameter DrawGrid
 
static constexpr EffectParameter dBMin
 
static constexpr EffectParameter dBMax
 

Detailed Description

Parameters of the Equalization effects that persist in configuration files.

Definition at line 29 of file EqualizationParameters.h.

Member Enumeration Documentation

◆ kInterpolations

Enumerator
kBspline 
kCosine 
kCubic 
nInterpolations 

Definition at line 30 of file EqualizationParameters.h.

Constructor & Destructor Documentation

◆ EqualizationParameters()

EqualizationParameters::EqualizationParameters ( const EffectSettingsManager manager)
explicit

Definition at line 26 of file EqualizationParameters.cpp.

30 , mM { FilterLength.def }
32 , mLin { InterpLin.def }
33{
42}
wxT("CloseDown"))
const RegistryPath & CurrentSettingsGroup()
Component of a configuration key path, for last-used destructive settings.
static const AttachedProjectObjects::RegisteredFactory manager
bool GetConfig(const EffectDefinitionInterface &ident, ConfigurationType type, const RegistryPath &group, const RegistryPath &key, Value &var, const Value &defval)
const Type def
Default value.
const EffectSettingsManager & mSettingsManager
static constexpr EffectParameter dBMax
static constexpr EffectParameter dBMin
static constexpr EnumParameter InterpMeth
static constexpr EffectParameter CurveName
static constexpr EffectParameter DrawGrid
static constexpr EffectParameter FilterLength
static constexpr EffectParameter DrawMode
static constexpr EffectParameter InterpLin

References CurrentSettingsGroup(), dBMax, dBMin, EffectParameter< Structure, Member, Type, Value >::def, DrawGrid, DrawMode, PluginSettings::GetConfig(), manager, mdBMax, mdBMin, mDrawGrid, mDrawMode, PluginSettings::Private, and wxT().

Here is the call graph for this function:

Member Function Documentation

◆ IsLinear()

bool EqualizationParameters::IsLinear ( ) const

Definition at line 71 of file EqualizationParameters.cpp.

72{
73 // If sliders show (!mDrawMode), always use the log envelope
74 return mDrawMode && mLin;
75}

References mDrawMode, and mLin.

Referenced by EqualizationFilter::CalcFilter(), EqualizationFilter::ChooseEnvelopeToPaint(), and EqualizationCurvesList::EnvelopeUpdated().

Here is the caller graph for this function:

◆ LoadDefaults()

void EqualizationParameters::LoadDefaults ( int  options)

Definition at line 44 of file EqualizationParameters.cpp.

45{
50
51 if( options == kEqOptionCurve)
52 mDrawMode = true;
53 if( options == kEqOptionGraphic)
54 mDrawMode = false;
55}
const int kEqOptionCurve
const int kEqOptionGraphic

References dBMax, dBMin, EffectParameter< Structure, Member, Type, Value >::def, DrawGrid, DrawMode, kEqOptionCurve, kEqOptionGraphic, mdBMax, mdBMin, mDrawGrid, and mDrawMode.

Referenced by EqualizationBase::DoLoadFactoryDefaults().

Here is the caller graph for this function:

◆ SaveConfig()

void EqualizationParameters::SaveConfig ( ) const

Definition at line 57 of file EqualizationParameters.cpp.

59{
60 // TODO: just visit these effect settings the default way
62 CurrentSettingsGroup(), wxT("dBMin"), mdBMin);
64 CurrentSettingsGroup(), wxT("dBMax"), mdBMax);
66 CurrentSettingsGroup(), wxT("DrawMode"), mDrawMode);
68 CurrentSettingsGroup(), wxT("DrawGrid"), mDrawGrid);
69}
bool SetConfig(const EffectDefinitionInterface &ident, ConfigurationType type, const RegistryPath &group, const RegistryPath &key, const Value &value)

References CurrentSettingsGroup(), mdBMax, mdBMin, mDrawGrid, mDrawMode, mSettingsManager, PluginSettings::Private, PluginSettings::SetConfig(), and wxT().

Here is the call graph for this function:

Member Data Documentation

◆ CurveName

constexpr EffectParameter EqualizationParameters::CurveName
staticconstexpr
Initial value:
L"CurveName", L"unnamed", L"", L"", L""}

Definition at line 57 of file EqualizationParameters.h.

◆ dBMax

constexpr EffectParameter EqualizationParameters::dBMax
staticconstexpr
Initial value:
L"", 30.0f, 0.0, 60.0, 0 }

Definition at line 69 of file EqualizationParameters.h.

Referenced by EqualizationParameters(), and LoadDefaults().

◆ dBMin

constexpr EffectParameter EqualizationParameters::dBMin
staticconstexpr
Initial value:
L"", -30.0f, -120.0, -10.0, 0 }

Definition at line 67 of file EqualizationParameters.h.

Referenced by EqualizationParameters(), and LoadDefaults().

◆ DrawGrid

constexpr EffectParameter EqualizationParameters::DrawGrid
staticconstexpr
Initial value:
L"", true, false, true, false }

Definition at line 65 of file EqualizationParameters.h.

Referenced by EqualizationParameters(), and LoadDefaults().

◆ DrawMode

constexpr EffectParameter EqualizationParameters::DrawMode
staticconstexpr
Initial value:
L"", true, false, true, false }

Definition at line 63 of file EqualizationParameters.h.

Referenced by EqualizationParameters(), and LoadDefaults().

◆ FilterLength

constexpr EffectParameter EqualizationParameters::FilterLength
staticconstexpr
Initial value:
L"FilterLength", 8191, 21, 8191, 0 }

Definition at line 55 of file EqualizationParameters.h.

Referenced by EqualizationBase::Parameters().

◆ InterpLin

constexpr EffectParameter EqualizationParameters::InterpLin
staticconstexpr
Initial value:
L"InterpolateLin", false, false, true, false }

Definition at line 59 of file EqualizationParameters.h.

Referenced by EqualizationBase::Parameters().

◆ InterpMeth

constexpr EnumParameter EqualizationParameters::InterpMeth
staticconstexpr
Initial value:
L"InterpolationMethod", 0, 0, 0, 0, kInterpStrings, nInterpolations }
static const EnumValueSymbol kInterpStrings[nInterpolations]

Definition at line 61 of file EqualizationParameters.h.

Referenced by EqualizationBase::Parameters().

◆ kInterpStrings

const EnumValueSymbol EqualizationParameters::kInterpStrings
static
Initial value:
=
{
{ XO("B-spline") },
{ XO("Cosine") },
{ XO("Cubic") }
}
XO("Cut/Copy/Paste")

Definition at line 36 of file EqualizationParameters.h.

Referenced by EqualizationUI::PopulateOrExchange().

◆ mCurveName

wxString EqualizationParameters::mCurveName

◆ mdBMax

float EqualizationParameters::mdBMax

◆ mdBMin

float EqualizationParameters::mdBMin

◆ mDrawGrid

bool EqualizationParameters::mDrawGrid

◆ mDrawMode

bool EqualizationParameters::mDrawMode

◆ mInterp

int EqualizationParameters::mInterp

Definition at line 49 of file EqualizationParameters.h.

Referenced by EqualizationBandSliders::GraphicEQ().

◆ mLin

bool EqualizationParameters::mLin

◆ mM

size_t EqualizationParameters::mM

◆ mSettingsManager

const EffectSettingsManager& EqualizationParameters::mSettingsManager

Definition at line 43 of file EqualizationParameters.h.

Referenced by SaveConfig().


The documentation for this struct was generated from the following files: