17#ifndef __AUDACITY_EFFECT_TRUNC_SILENCE__
18#define __AUDACITY_EFFECT_TRUNC_SILENCE__
23#include <wx/weakref.h>
67 int whichTrack,
double* inputLength =
nullptr,
68 double* minInputLength =
nullptr)
const;
101 unsigned iGroup,
unsigned nGroups,
102 double &totalCutLen);
123 DECLARE_EVENT_TABLE()
135 L
"Threshold", -20.0, -80.0, -20.0, 1 };
139 L
"Minimum", 0.5, 0.001, 10000.0, 1 };
141 L
"Truncate", 0.5, 0.0, 10000.0, 1 };
143 L
"Compress", 50.0, 0.0, 99.9, 1 };
145 L
"Independent",
false,
false,
true, 1 };
declares abstract base class Track, TrackList, and iterators over TrackList
static Settings & settings()
CommandParameters, derived from wxFileConfig, is essentially doing the same things as the SettingsVis...
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
Performs effect computation.
Hold values to send to effect output meters.
Interface for manipulations of an Effect's settings.
Truncate Silence automatically reduces the length of passages where the volume is below a set thresho...
bool TransferDataToWindow(const EffectSettings &settings) override
static EffectTruncSilence * FetchParameters(EffectTruncSilence &e, EffectSettings &)
std::unique_ptr< EffectEditor > PopulateOrExchange(ShuttleGui &S, EffectInstance &instance, EffectSettingsAccess &access, const EffectOutputs *pOutputs) override
Add controls to effect panel; always succeeds.
bool Process(EffectInstance &instance, EffectSettings &settings) override
static constexpr EnumParameter ActIndex
static constexpr EffectParameter Independent
wxWeakRef< wxWindow > mUIParent
ManualPageID ManualPage() const override
Name of a page in the Audacity alpha manual, default is empty.
wxTextCtrl * mThresholdText
double mInitialAllowedSilence
bool NeedsDither() const override
double CalcPreviewInputLength(const EffectSettings &settings, double previewLength) const override
void OnControlChange(wxCommandEvent &evt)
static constexpr EffectParameter Minimum
bool FindSilences(RegionList &silences, const TrackIterRange< const WaveTrack > &range)
bool Analyze(RegionList &silenceList, RegionList &trackSilences, const WaveTrack &wt, sampleCount *silentFrame, sampleCount *index, int whichTrack, double *inputLength=nullptr, double *minInputLength=nullptr) const
virtual ~EffectTruncSilence()
wxCheckBox * mIndependent
bool TransferDataFromWindow(EffectSettings &settings) override
double mSilenceCompressPercent
static constexpr EffectParameter Truncate
EffectType GetType() const override
Type determines how it behaves.
static const EnumValueSymbol kActionStrings[nActions]
double mTruncLongestAllowedSilence
static constexpr EffectParameter Threshold
bool ProcessIndependently()
wxTextCtrl * mTruncLongestAllowedSilenceT
static const ComponentInterfaceSymbol Symbol
const EffectParameterMethods & Parameters() const override
TranslatableString GetDescription() const override
ComponentInterfaceSymbol GetSymbol() const override
bool LoadSettings(const CommandParameters &parms, EffectSettings &settings) const override
Restore settings from keys and values.
wxTextCtrl * mInitialAllowedSilenceT
wxTextCtrl * mSilenceCompressPercentT
static constexpr EffectParameter Compress
bool DoRemoval(const RegionList &silences, const TrackIterRange< Track > &range, unsigned iGroup, unsigned nGroups, double &totalCutLen)
void Intersect(RegionList &dest, const RegionList &src)
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Holds a msgid for the translation catalog; may also bind format arguments.
A Track that contains audio waveform data.
Positions or offsets within audio files need a wide type.
Externalized state of a plug-in.
Range between two TrackIters, usable in range-for statements, and with Visit member functions.