28 return batchParameters;
81 EffectSettings&,
const float*
const* inBlock,
float*
const* outBlock,
84 for (
decltype(blockLen) i = 0; i < blockLen; i++)
86 outBlock[0][i] = inBlock[0][i] *
mRatio;
123 bool hasPitchOrSpeed =
124 any_of(
begin(range),
end(range), [
this](
auto* pTrack) {
132 for (
const auto pChannel : t->Channels())
136 const float min = pair.first, max = pair.second;
137 const float newpeak = std::max(fabs(
min), fabs(max));
154 double dB = std::clamp<double>(dBInit,
Amp.
min,
Amp.
max);
std::optional< std::unique_ptr< EffectSettingsAccess::Message > > OptionalMessage
static Settings & settings()
OptionalMessage LoadFactoryDefaults(EffectSettings &settings) const override
unsigned GetAudioInCount() const override
How many input buffers to allocate at once.
const EffectParameterMethods & Parameters() const override
size_t ProcessBlock(EffectSettings &settings, const float *const *inBlock, float *const *outBlock, size_t blockLen) override
Called for destructive effect computation.
std::any BeginPreview(const EffectSettings &settings) override
Called when Preview() starts, to allow temporary effect state changes.
static const ComponentInterfaceSymbol Symbol
static constexpr EffectParameter Ratio
EffectType GetType() const override
Type determines how it behaves.
OptionalMessage DoLoadFactoryDefaults(EffectSettings &settings)
unsigned GetAudioOutCount() const override
How many output buffers to allocate at once.
virtual ~AmplifyBase() override
static constexpr EffectParameter Amp
ComponentInterfaceSymbol GetSymbol() const override
static constexpr EffectParameter Clipping
Generates EffectParameterMethods overrides from variadic template arguments.
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
void SetLinearEffectFlag(bool linearEffectFlag)
const TrackList * inputTracks() const
bool IsBatchProcessing() const override
Interface for manipulations of an Effect's settings.
virtual void Reset(Effect &effect) const =0
void DestroyOutputTracks() const
std::shared_ptr< EffectOutputTracks > MakeOutputTracks()
StatefulPerTrackEffect & GetEffect() const
auto Selected() -> TrackIterRange< TrackType >
A Track that contains audio waveform data.
WAVE_TRACK_API bool HasPitchOrSpeed(const WaveTrack &track, double t0, double t1)
WAVE_TRACK_API std::pair< float, float > GetMinMax(const WaveChannel &channel, double t0, double t1, bool mayThrow=true)
const char * end(const char *str) noexcept
const char * begin(const char *str) noexcept
const Type def
Default value.
const Type min
Minimum value.
const Type max
Maximum value.
Externalized state of a plug-in.