DSPark 1.6.1
Header-only audio DSP framework in pure C++20 — zero dependencies
Loading...
Searching...
No Matches
dspark::AlgorithmicReverb< T > Class Template Reference

16-line FDN reverb with Jot absorption and 6 presets. More...

#include <AlgorithmicReverb.h>

Collaboration diagram for dspark::AlgorithmicReverb< T >:

Classes

struct  CachedParams
 
struct  PresetValues
 
struct  SmoothRandomLFO
 Hermite-interpolated random noise generator for organic modulation. More...
 

Public Types

enum class  Type {
  Room , Hall , Chamber , Plate ,
  Spring , Cathedral
}
 Reverb type presets. More...
 
enum class  Quality { Full , Eco }
 Engine quality / CPU cost trade-off (see setQuality()). More...
 

Public Member Functions

 ~AlgorithmicReverb ()=default
 
void prepare (const AudioSpec &spec)
 Prepares the reverberation engine and allocates required memory.
 
void processBlock (AudioBufferView< T > buffer) noexcept
 Processes an audio block in-place with zero allocations.
 
std::pair< T, T > processSample (T input) noexcept
 Processes a single sample and returns a stereo pair.
 
void reset () noexcept
 Resets all internal delay buffers, filters, and LFO phases.
 
void setType (Type type) noexcept
 
void setQuality (Quality q) noexcept
 Selects the engine quality / CPU cost trade-off.
 
void setDecay (T seconds) noexcept
 
void setMix (T dryWet) noexcept
 
void setSize (T size) noexcept
 
void setDamping (T amount) noexcept
 Sets high-frequency damping (0 = bright, 1 = dark).
 
void setPreDelay (T ms) noexcept
 
void setDiffusion (T amount) noexcept
 
void setModulation (T amount) noexcept
 
void setWidth (T width) noexcept
 Sets stereo width of the late reverb tail.
 
void setErToLateDelay (T ms) noexcept
 
void setHighDecayMultiplier (T mult) noexcept
 Sets HF decay as a multiplier of mid decay time.
 
void setBassDecayMultiplier (T mult) noexcept
 Sets bass decay as a multiplier of mid decay time.
 
void setHighCrossover (T hz) noexcept
 Frequency where the HF decay transition is centered.
 
void setBassCrossover (T hz) noexcept
 Frequency below which bass decay multiplier applies.
 
void setEarlyLevel (T dB) noexcept
 
void setLateLevel (T dB) noexcept
 
void setModRate (T hz) noexcept
 
void setToneLowCut (T hz) noexcept
 Sets a post-reverb low-cut filter on the wet signal (12 dB/oct).
 
void setToneHighCut (T hz) noexcept
 Sets a post-reverb high-cut filter on the wet signal (12 dB/oct).
 
Type getType () const noexcept
 
Quality getQuality () const noexcept
 
getDecay () const noexcept
 
getMix () const noexcept
 
getHighDecayMultiplier () const noexcept
 
getBassDecayMultiplier () const noexcept
 
getWidth () const noexcept
 
getHighCrossover () const noexcept
 
getBassCrossover () const noexcept
 
std::vector< uint8_t > getState () const
 Serializes the parameter state (setup/UI threads; allocates).
 
bool setState (const uint8_t *data, size_t size)
 Restores parameters from a blob (tolerant; rejects foreign ids).
 

Protected Types

enum  : uint32_t {
  kUserDecay = 1u , kUserSize = 2u , kUserDamping = 4u , kUserDiffusion = 8u ,
  kUserBassDecay = 16u , kUserHighXover = 32u , kUserBassXover = 64u , kUserModDepth = 128u ,
  kUserModRate = 256u , kUserEarly = 512u , kUserLate = 1024u , kUserErToLate = 2048u
}
 

Protected Member Functions

void markUserParam (uint32_t bit) noexcept
 
nextFilteredNoise () noexcept
 Lowpass-filtered white noise for modulation randomization.
 
nextFilteredNoiseEco () noexcept
 
processAllpass (RingBuffer< T > &buf, int delay, T coeff, T input) noexcept
 
processAllpassModulated (RingBuffer< T > &buf, int baseDelay, T modAmount, T coeff, T input, bool linearInterp) noexcept
 
void drainPendingChanges () noexcept
 Drains deferred parameter changes on the audio thread.
 
void refreshCachedParams () noexcept
 Pulls the atomic parameters into the block-local cache (audio thread).
 
std::pair< T, T > processSampleInternal (T input) noexcept
 Core per-sample processing - returns wet {L, R}.
 
void updateDecayParams () noexcept
 Computes per-line Jot absorption filter coefficients.
 
void updateDelayLengths () noexcept
 
void updateDiffCoeffs () noexcept
 
void updateModulation () noexcept
 
void generateERTapsForType (Type type) noexcept
 
void generateERTaps (double minMs, double maxMs, int numTaps) noexcept
 
void commitPreset (const PresetValues &p) noexcept
 
void applyPreset (Type type)
 

Static Protected Member Functions

static void hadamardInPlace (std::array< T, kFDNSize > &x) noexcept
 In-place Hadamard 16x16 via Fast Walsh-Hadamard butterfly.
 
static void hadamard8InPlace (std::array< T, kFDNSize > &x) noexcept
 In-place Hadamard 8x8 on the first 8 elements (Eco quality).
 
static void householderInPlace (std::array< T, kFDNSize > &x, int n) noexcept
 In-place Householder reflection for 16 channels.
 
static const std::vector< uint8_t > & getPrimeSieve () noexcept
 
static int nearestPrime (int n) noexcept
 

Protected Attributes

AudioSpec spec_ {}
 
std::array< RingBuffer< T >, kFDNSizefdnDelays_
 
std::array< int, kFDNSizefdnDelayLens_ {}
 
std::array< T, kFDNSizeabsB0_ {}
 
std::array< T, kFDNSizeabsB1_ {}
 
std::array< T, kFDNSizeabsA1_ {}
 
std::array< T, kFDNSizeabsX1_ {}
 
std::array< T, kFDNSizeabsState_ {}
 
std::array< T, kFDNSizebassRatio_ {}
 
std::array< T, kFDNSizebassState_ {}
 
std::array< T, kFDNSizedcZ_ {}
 
std::array< RingBuffer< T >, kFDNSizefbAPBufsA_
 
std::array< RingBuffer< T >, kFDNSizefbAPBufsB_
 
std::array< int, kFDNSizefbAPDelaysA_ {}
 
std::array< int, kFDNSizefbAPDelaysB_ {}
 
fbAPCoeff_ = T(0.6)
 
std::array< RingBuffer< T >, kFDNSizeintAPBufsA_
 
std::array< RingBuffer< T >, kFDNSizeintAPBufsB_
 
std::array< int, kFDNSizeintAPDelaysA_ {}
 
std::array< int, kFDNSizeintAPDelaysB_ {}
 
std::array< T, kFDNSizeprevFeedback_ {}
 
fbSmooth_ = T(0.3)
 
std::array< SmoothRandomLFO, kFDNSizemodLFOA_
 
std::array< SmoothRandomLFO, kFDNSizemodLFOB_
 
std::array< T, kFDNSizeapInterpState_ {}
 
uint32_t noiseState_ = 1
 
noiseLP_ = T(0)
 
noiseCoeff_ = T(0)
 
noiseDepth_ = T(0)
 
bool eco_ = false
 
int nLines_ = kFDNSize
 
std::array< T, kFDNSizemodACache_ {}
 
std::array< T, kFDNSizemodBCache_ {}
 
noiseND_ = T(0)
 
int ctrlPhase_ = 0
 
noiseCoeffEco_ = T(0)
 
std::array< RingBuffer< T >, kDiffStagesdiffBufs_
 
std::array< int, kDiffStagesdiffDelays_ {}
 
std::array< T, kDiffStagesdiffCoeffs_ {}
 
std::array< RingBuffer< T >, kFDNSizeparAPBufs_
 
std::array< int, kFDNSizeparAPDelays_ {}
 
parAPCoeff_ = T(0.65)
 
std::array< RingBuffer< T >, kFDNSizediffuserStep2_
 
std::array< int, kFDNSizediffuserStep2Delays_ {}
 
std::array< RingBuffer< T >, kOutDiffStagesoutDiffBufsL_
 
std::array< RingBuffer< T >, kOutDiffStagesoutDiffBufsR_
 
std::array< int, kOutDiffStagesoutDiffDelaysL_ {}
 
std::array< int, kOutDiffStagesoutDiffDelaysR_ {}
 
outDiffCoeff_ = T(0.45)
 
RingBuffer< T > erBuf_
 
std::array< int, kMaxERTapserTapsL_ {}
 
std::array< int, kMaxERTapserTapsR_ {}
 
std::array< T, kMaxERTapserGainsL_ {}
 
std::array< T, kMaxERTapserGainsR_ {}
 
std::array< T, kMaxERTapserAbsCoeffs_ {}
 
std::array< T, kMaxERTapserLPStateL_ {}
 
std::array< T, kMaxERTapserLPStateR_ {}
 
int numERTaps_ = 0
 
RingBuffer< T > preDelayBuf_
 
std::atomic< int > preDelaySamples_ { 0 }
 
RingBuffer< T > erToLateBuf_
 
std::atomic< int > erToLateSamples_ { 0 }
 
Biquad< T, 2 > toneLPBiquad_
 
Biquad< T, 2 > toneHPBiquad_
 
bool toneLPActive_ = false
 
bool toneHPActive_ = false
 
DryWetMixer< T > mixer_
 
std::atomic< Typetype_ { Type::Room }
 
std::atomic< T > decayTime_ { T(1) }
 
std::atomic< T > size_ { T(0.5) }
 
std::atomic< T > damping_ { T(0.5) }
 
std::atomic< T > diffusion_ { T(0.7) }
 
std::atomic< T > modDepth_ { T(0.1) }
 
std::atomic< T > modRate_ { T(1) }
 
std::atomic< T > preDelayMs_ { T(0) }
 
std::atomic< T > erToLateMs_ { T(0) }
 
std::atomic< T > mix_ { T(0.3) }
 
std::atomic< T > earlyLevel_ { T(1) }
 
std::atomic< T > lateLevel_ { T(1) }
 
std::atomic< T > width_ { T(1) }
 
std::atomic< T > highDecayMult_ { T(0.5) }
 
std::atomic< T > bassDecayMult_ { T(1.2) }
 
std::atomic< T > highCrossover_ { T(5000) }
 
std::atomic< T > bassCrossover_ { T(200) }
 
std::atomic< Qualityquality_ { Quality::Full }
 
std::atomic< bool > presetDirty_ { false }
 
std::atomic< bool > paramsDirty_ { false }
 
std::atomic< uint32_t > userParamMask_ { 0u }
 
std::atomic< bool > toneDirty_ { false }
 
std::atomic< bool > qualityDirty_ { false }
 
std::atomic< T > toneLowCutHz_ { T(-1) }
 
std::atomic< T > toneHighCutHz_ { T(-1) }
 
bassLPCoeff_ = T(0.026)
 
dcCoeff_ = T(0.003)
 
std::atomic< T > modDepthA_ { T(1) }
 
std::atomic< T > modDepthB_ { T(0.5) }
 
CachedParams cachedParams_ {}
 

Static Protected Attributes

static constexpr int kFDNSize = 16
 
static constexpr int kDiffStages = 8
 
static constexpr int kMaxERTaps = 40
 
static constexpr int kNumMultiTaps = 7
 
static constexpr int kOutDiffStages = 2
 
static constexpr int kEcoLines = 8
 FDN lines in Eco quality.
 
static constexpr int kEcoCtrlInterval = 16
 modulation refresh period (samples)
 
static constexpr int kEcoERTaps = 12
 early-reflection tap cap in Eco
 
static constexpr T kInputGain = T(1) / T(8)
 
static constexpr T kOutputNorm = T(1) / T(5.0)
 
static constexpr T kOutputNormEco = T(0.32)
 
static constexpr int kOutSignL_ [kFDNSize]
 
static constexpr int kOutSignR_ [kFDNSize]
 
static constexpr int kMultiTapLineL_ [kNumMultiTaps] = {0, 2, 5, 7, 9, 12, 14}
 
static constexpr int kMultiTapLineR_ [kNumMultiTaps] = {1, 3, 4, 8, 10, 13, 15}
 
static constexpr double kMultiTapFracL_ [kNumMultiTaps] = {0.37, 0.67, 0.23, 0.81, 0.44, 0.59, 0.31}
 
static constexpr double kMultiTapFracR_ [kNumMultiTaps] = {0.43, 0.71, 0.29, 0.63, 0.47, 0.53, 0.37}
 
static constexpr int kMultiTapSignL_ [kNumMultiTaps] = {+1, -1, +1, -1, +1, -1, +1}
 
static constexpr int kMultiTapSignR_ [kNumMultiTaps] = {+1, +1, -1, +1, -1, +1, -1}
 
static constexpr double kBaseDelaysMs_ [kFDNSize]
 
static constexpr double kDiffDelaysMs_ [kDiffStages]
 
static constexpr double kDiffBaseCoeffs_ [kDiffStages]
 
static constexpr int kFbAPStages = 2
 
static constexpr double kFbAPRatioA_ = 0.25
 
static constexpr double kFbAPRatioB_ = 0.35
 
static constexpr double kParAPDelaysMs_ [kFDNSize]
 
static constexpr double kDiffuserStep2Ms_ [kFDNSize]
 
static constexpr double kOutDiffDelaysMsL_ [kOutDiffStages] = {1.47, 2.31}
 
static constexpr double kOutDiffDelaysMsR_ [kOutDiffStages] = {1.63, 2.47}
 
static constexpr T intAPCoeff_ = T(0.5)
 
static constexpr double kIntAPRatioA_ = 0.15
 
static constexpr double kIntAPRatioB_ = 0.20
 
static constexpr int kPrimeTableMax = 131072
 

Detailed Description

template<FloatType T>
class dspark::AlgorithmicReverb< T >

16-line FDN reverb with Jot absorption and 6 presets.

Template Parameters
TSample type (float or double).

Definition at line 148 of file AlgorithmicReverb.h.

Member Enumeration Documentation

◆ anonymous enum

template<FloatType T>
anonymous enum : uint32_t
protected
Enumerator
kUserDecay 
kUserSize 
kUserDamping 
kUserDiffusion 
kUserBassDecay 
kUserHighXover 
kUserBassXover 
kUserModDepth 
kUserModRate 
kUserEarly 
kUserLate 
kUserErToLate 

Definition at line 1087 of file AlgorithmicReverb.h.

◆ Quality

template<FloatType T>
enum class dspark::AlgorithmicReverb::Quality
strong

Engine quality / CPU cost trade-off (see setQuality()).

Enumerator
Full 

Complete 16-line engine. Default; bit-identical to previous releases.

Eco 

Reduced engine, roughly 3-4x cheaper. For constrained targets.

Definition at line 165 of file AlgorithmicReverb.h.

◆ Type

template<FloatType T>
enum class dspark::AlgorithmicReverb::Type
strong

Reverb type presets.

Enumerator
Room 

Small room, short decay, dense close reflections.

Hall 

Concert hall, spacious, long smooth tail.

Chamber 

Recording studio chamber, warm, balanced.

Plate 

Metal plate, dense shimmer, no early reflections.

Spring 

Spring reverb, bouncy vintage character.

Cathedral 

Large cathedral, immense decay, vast space.

Definition at line 152 of file AlgorithmicReverb.h.

Constructor & Destructor Documentation

◆ ~AlgorithmicReverb()

template<FloatType T>
dspark::AlgorithmicReverb< T >::~AlgorithmicReverb ( )
default

Member Function Documentation

◆ applyPreset()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::applyPreset ( Type  type)
inlineprotected

Definition at line 1944 of file AlgorithmicReverb.h.

◆ commitPreset()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::commitPreset ( const PresetValues p)
inlineprotectednoexcept

Definition at line 1922 of file AlgorithmicReverb.h.

◆ drainPendingChanges()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::drainPendingChanges ( )
inlineprotectednoexcept

Drains deferred parameter changes on the audio thread.

C2/C3 model: all mutations of non-atomic topology arrays (fdnDelayLens_, diffCoeffs_, ...) happen here, never from GUI-thread setters. The acquire-ordered exchanges synchronize with the release-stores in setType/setXxx. Called at the top of processBlock() and processSample(); each flag is pre-checked with a plain load so the per-sample path pays no RMW when nothing is pending.

Definition at line 1246 of file AlgorithmicReverb.h.

◆ generateERTaps()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::generateERTaps ( double  minMs,
double  maxMs,
int  numTaps 
)
inlineprotectednoexcept

Definition at line 1826 of file AlgorithmicReverb.h.

◆ generateERTapsForType()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::generateERTapsForType ( Type  type)
inlineprotectednoexcept

Regenerates the ER tap set for a reverb type, honouring the Eco cap. The taps are re-spread over the type's full min..max window, so a reduced count keeps the temporal coverage (and the 1/sqrt(N) gain normalization stays correct).

Definition at line 1812 of file AlgorithmicReverb.h.

◆ getBassCrossover()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getBassCrossover ( ) const
inlinenoexcept

Definition at line 712 of file AlgorithmicReverb.h.

◆ getBassDecayMultiplier()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getBassDecayMultiplier ( ) const
inlinenoexcept

Definition at line 709 of file AlgorithmicReverb.h.

◆ getDecay()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getDecay ( ) const
inlinenoexcept

Definition at line 706 of file AlgorithmicReverb.h.

◆ getHighCrossover()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getHighCrossover ( ) const
inlinenoexcept

Definition at line 711 of file AlgorithmicReverb.h.

◆ getHighDecayMultiplier()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getHighDecayMultiplier ( ) const
inlinenoexcept

Definition at line 708 of file AlgorithmicReverb.h.

◆ getMix()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getMix ( ) const
inlinenoexcept

Definition at line 707 of file AlgorithmicReverb.h.

◆ getPrimeSieve()

template<FloatType T>
static const std::vector< uint8_t > & dspark::AlgorithmicReverb< T >::getPrimeSieve ( )
inlinestaticprotectednoexcept

Definition at line 1874 of file AlgorithmicReverb.h.

◆ getQuality()

template<FloatType T>
Quality dspark::AlgorithmicReverb< T >::getQuality ( ) const
inlinenoexcept

Definition at line 705 of file AlgorithmicReverb.h.

◆ getState()

template<FloatType T>
std::vector< uint8_t > dspark::AlgorithmicReverb< T >::getState ( ) const
inline

Serializes the parameter state (setup/UI threads; allocates).

Definition at line 716 of file AlgorithmicReverb.h.

◆ getType()

template<FloatType T>
Type dspark::AlgorithmicReverb< T >::getType ( ) const
inlinenoexcept

Definition at line 704 of file AlgorithmicReverb.h.

◆ getWidth()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::getWidth ( ) const
inlinenoexcept

Definition at line 710 of file AlgorithmicReverb.h.

◆ hadamard8InPlace()

template<FloatType T>
static void dspark::AlgorithmicReverb< T >::hadamard8InPlace ( std::array< T, kFDNSize > &  x)
inlinestaticprotectednoexcept

In-place Hadamard 8x8 on the first 8 elements (Eco quality).

3-stage butterfly, normalized by 1/sqrt(8). Elements 8..15 untouched.

Definition at line 1189 of file AlgorithmicReverb.h.

◆ hadamardInPlace()

template<FloatType T>
static void dspark::AlgorithmicReverb< T >::hadamardInPlace ( std::array< T, kFDNSize > &  x)
inlinestaticprotectednoexcept

In-place Hadamard 16x16 via Fast Walsh-Hadamard butterfly.

4-stage butterfly, 64 add/sub, normalized by 1/sqrt(16)=1/4. Used in diffusion stages where maximum inter-channel mixing is desired.

Definition at line 1165 of file AlgorithmicReverb.h.

◆ householderInPlace()

template<FloatType T>
static void dspark::AlgorithmicReverb< T >::householderInPlace ( std::array< T, kFDNSize > &  x,
int  n 
)
inlinestaticprotectednoexcept

In-place Householder reflection for 16 channels.

H = I - (2/N) * ones. Each output = input - (2/N) * sum. Provides moderate cross-feeding without locking delays together, as recommended by Signalsmith for FDN feedback mixing.

Definition at line 1212 of file AlgorithmicReverb.h.

◆ markUserParam()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::markUserParam ( uint32_t  bit)
inlineprotectednoexcept

Definition at line 1094 of file AlgorithmicReverb.h.

◆ nearestPrime()

template<FloatType T>
static int dspark::AlgorithmicReverb< T >::nearestPrime ( int  n)
inlinestaticprotectednoexcept

Definition at line 1890 of file AlgorithmicReverb.h.

◆ nextFilteredNoise()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::nextFilteredNoise ( )
inlineprotectednoexcept

Lowpass-filtered white noise for modulation randomization.

Definition at line 1113 of file AlgorithmicReverb.h.

◆ nextFilteredNoiseEco()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::nextFilteredNoiseEco ( )
inlineprotectednoexcept

Control-rate variant (Eco): same generator, coefficient scaled so the ~3 Hz cutoff is preserved when called every kEcoCtrlInterval samples.

Definition at line 1124 of file AlgorithmicReverb.h.

◆ prepare()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::prepare ( const AudioSpec spec)
inline

Prepares the reverberation engine and allocates required memory.

Initializes delay lines, filters, and LFOs based on the specified sample rate. This method avoids memory allocations on the audio thread and must be called prior to any processing.

An invalid spec (non-positive or non-finite fields) is a no-op that keeps the previous state.

Parameters
specAudio specification detailing sample rate and maximum block size.

Definition at line 187 of file AlgorithmicReverb.h.

◆ processAllpass()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::processAllpass ( RingBuffer< T > &  buf,
int  delay,
coeff,
input 
)
inlineprotectednoexcept

Definition at line 1133 of file AlgorithmicReverb.h.

◆ processAllpassModulated()

template<FloatType T>
T dspark::AlgorithmicReverb< T >::processAllpassModulated ( RingBuffer< T > &  buf,
int  baseDelay,
modAmount,
coeff,
input,
bool  linearInterp 
)
inlineprotectednoexcept

Definition at line 1142 of file AlgorithmicReverb.h.

◆ processBlock()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::processBlock ( AudioBufferView< T >  buffer)
inlinenoexcept

Processes an audio block in-place with zero allocations.

Applies the complete FDN reverberation algorithm, handling mono, stereo, and mid/side signal edge cases. Thread-safe and designed for the hot path.

Parameters
bufferView of the audio buffers (supports mono or stereo).

Definition at line 289 of file AlgorithmicReverb.h.

◆ processSample()

template<FloatType T>
std::pair< T, T > dspark::AlgorithmicReverb< T >::processSample ( input)
inlinenoexcept

Processes a single sample and returns a stereo pair.

Pending parameter/preset/quality changes are drained here too (per-sample streams that never call processBlock() used to keep the old topology forever: a setType() was published but never applied).

Parameters
inputThe mono input sample to reverberate.
Returns
std::pair<T, T> A pair containing the {Left, Right} reverberated output.

Definition at line 365 of file AlgorithmicReverb.h.

◆ processSampleInternal()

template<FloatType T>
std::pair< T, T > dspark::AlgorithmicReverb< T >::processSampleInternal ( input)
inlineprotectednoexcept

Core per-sample processing - returns wet {L, R}.

Definition at line 1344 of file AlgorithmicReverb.h.

◆ refreshCachedParams()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::refreshCachedParams ( )
inlineprotectednoexcept

Pulls the atomic parameters into the block-local cache (audio thread).

Definition at line 1332 of file AlgorithmicReverb.h.

◆ reset()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::reset ( )
inlinenoexcept

Resets all internal delay buffers, filters, and LFO phases.

Prevents feedback clicks or ringing when transport stops or topology changes.

Definition at line 380 of file AlgorithmicReverb.h.

◆ setBassCrossover()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setBassCrossover ( hz)
inlinenoexcept

Frequency below which bass decay multiplier applies.

Parameters
hzCrossover in Hz (50 - 500). Default: 200.

Definition at line 642 of file AlgorithmicReverb.h.

◆ setBassDecayMultiplier()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setBassDecayMultiplier ( mult)
inlinenoexcept

Sets bass decay as a multiplier of mid decay time.

0.5 = bass decays 2x faster (tight). 1.0 = bass same as mid (neutral). 1.5 = bass lingers 1.5x longer (natural large room). 2.0 = bass lingers 2x longer (boomy).

Parameters
multMultiplier (0.3 - 3.0).

Definition at line 607 of file AlgorithmicReverb.h.

◆ setDamping()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setDamping ( amount)
inlinenoexcept

Sets high-frequency damping (0 = bright, 1 = dark).

Maps internally to highDecayMultiplier: 0->1.0 (HF=mid), 1->0.1 (HF 10x faster). For finer control, use setHighDecayMultiplier() directly.

Definition at line 506 of file AlgorithmicReverb.h.

◆ setDecay()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setDecay ( seconds)
inlinenoexcept

Definition at line 473 of file AlgorithmicReverb.h.

◆ setDiffusion()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setDiffusion ( amount)
inlinenoexcept

Definition at line 529 of file AlgorithmicReverb.h.

◆ setEarlyLevel()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setEarlyLevel ( dB)
inlinenoexcept

Definition at line 655 of file AlgorithmicReverb.h.

◆ setErToLateDelay()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setErToLateDelay ( ms)
inlinenoexcept

Definition at line 561 of file AlgorithmicReverb.h.

◆ setHighCrossover()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setHighCrossover ( hz)
inlinenoexcept

Frequency where the HF decay transition is centered.

The per-line absorption is a first-order pole-zero shelf pinned to the mid decay at DC and the HF decay at Nyquist (the T60 anchors stay exact for any crossover); this sets where the transition happens: the decay midpoint (geometric mean of the mid and HF loop gains) lands at this frequency. Lower values darken the tail earlier, higher values keep the damping in the top octaves only.

Parameters
hzCrossover in Hz (1000 - 16000). Default: 5000. Non-finite values are ignored.

Definition at line 629 of file AlgorithmicReverb.h.

◆ setHighDecayMultiplier()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setHighDecayMultiplier ( mult)
inlinenoexcept

Sets HF decay as a multiplier of mid decay time.

0.1 = HF decays 10x faster (very dark). 0.5 = HF decays 2x faster (natural room). 1.0 = HF same as mid (bright/metallic).

Parameters
multMultiplier (0.05 - 1.0).

Definition at line 586 of file AlgorithmicReverb.h.

◆ setLateLevel()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setLateLevel ( dB)
inlinenoexcept

Definition at line 662 of file AlgorithmicReverb.h.

◆ setMix()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setMix ( dryWet)
inlinenoexcept

Definition at line 482 of file AlgorithmicReverb.h.

◆ setModRate()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setModRate ( hz)
inlinenoexcept

Definition at line 669 of file AlgorithmicReverb.h.

◆ setModulation()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setModulation ( amount)
inlinenoexcept

Definition at line 537 of file AlgorithmicReverb.h.

◆ setPreDelay()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setPreDelay ( ms)
inlinenoexcept

Definition at line 516 of file AlgorithmicReverb.h.

◆ setQuality()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setQuality ( Quality  q)
inlinenoexcept

Selects the engine quality / CPU cost trade-off.

Quality::Full (default) runs the complete 16-line engine and is bit-identical to previous releases. Quality::Eco reduces the engine to roughly a quarter of the CPU cost for embedded and other constrained targets, keeping the same control set and decay calibration:

  • 8 FDN lines instead of 16 (alternate base delays keep the full 29.7-160 ms span, and per-line decay gains keep T60 exact)
  • modulation LFOs and noise updated at control rate (every 16 samples; steps are orders of magnitude below audibility at reverb mod rates)
  • linear interpolation in modulated allpasses (Dattorro-standard) instead of 4-point Hermite
  • single-stage input scatter (16 unique echo paths instead of 256)
  • no extra output taps (multi-tap / allpass taps); output density comes from the sign-weighted line sum plus output diffusion
  • early reflections capped at 12 taps

The audible difference is a somewhat lower tail density (most noticeable on long, exposed cathedral tails); short and mid rooms stay very close to Full.

Like setType(), this is an engine-mode switch, not an automation target: it is applied at the start of the next processBlock() and clears the reverb state (the running tail is dropped).

Parameters
qQuality::Full or Quality::Eco.

Definition at line 466 of file AlgorithmicReverb.h.

◆ setSize()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setSize ( size)
inlinenoexcept

Definition at line 492 of file AlgorithmicReverb.h.

◆ setState()

template<FloatType T>
bool dspark::AlgorithmicReverb< T >::setState ( const uint8_t *  data,
size_t  size 
)
inline

Restores parameters from a blob (tolerant; rejects foreign ids).

Definition at line 745 of file AlgorithmicReverb.h.

◆ setToneHighCut()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setToneHighCut ( hz)
inlinenoexcept

Sets a post-reverb high-cut filter on the wet signal (12 dB/oct).

Parameters
hzCutoff in Hz (0 = off, 2000-16000 typical).

Definition at line 693 of file AlgorithmicReverb.h.

◆ setToneLowCut()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setToneLowCut ( hz)
inlinenoexcept

Sets a post-reverb low-cut filter on the wet signal (12 dB/oct).

Parameters
hzCutoff in Hz (0 = off, 20-500 typical).

Definition at line 681 of file AlgorithmicReverb.h.

◆ setType()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setType ( Type  type)
inlinenoexcept

Definition at line 422 of file AlgorithmicReverb.h.

◆ setWidth()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::setWidth ( width)
inlinenoexcept

Sets stereo width of the late reverb tail.

Uses M/S processing: 0 = mono, 1 = natural stereo, 2 = extra wide. Applied after output diffusion, before combining with early reflections.

Parameters
widthStereo width (0.0 - 2.0). Default: 1.0.

Definition at line 555 of file AlgorithmicReverb.h.

◆ updateDecayParams()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::updateDecayParams ( )
inlineprotectednoexcept

Computes per-line Jot absorption filter coefficients.

Implements Jot/Chaigne (1991): each delay line gets a 1st-order pole-zero shelving IIR that produces frequency-dependent decay.

H(z) = (b0 + b1 * z^-1) / (1 + a1 * z^-1)

with |H(1)| = g_mid (decay at DC/mid), |H(-1)| = g_high (decay at Nyquist), and the transition midpoint sqrt(g_mid * g_high) placed at the highCrossover_ frequency (shared by all lines so the frequency-dependent T60 stays coherent across the FDN).

Definition at line 1655 of file AlgorithmicReverb.h.

◆ updateDelayLengths()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::updateDelayLengths ( )
inlineprotectednoexcept

Definition at line 1726 of file AlgorithmicReverb.h.

◆ updateDiffCoeffs()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::updateDiffCoeffs ( )
inlineprotectednoexcept

Definition at line 1780 of file AlgorithmicReverb.h.

◆ updateModulation()

template<FloatType T>
void dspark::AlgorithmicReverb< T >::updateModulation ( )
inlineprotectednoexcept

Definition at line 1791 of file AlgorithmicReverb.h.

Member Data Documentation

◆ absA1_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::absA1_ {}
protected

Definition at line 941 of file AlgorithmicReverb.h.

◆ absB0_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::absB0_ {}
protected

Definition at line 939 of file AlgorithmicReverb.h.

◆ absB1_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::absB1_ {}
protected

Definition at line 940 of file AlgorithmicReverb.h.

◆ absState_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::absState_ {}
protected

Definition at line 943 of file AlgorithmicReverb.h.

◆ absX1_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::absX1_ {}
protected

Definition at line 942 of file AlgorithmicReverb.h.

◆ apInterpState_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::apInterpState_ {}
protected

Definition at line 977 of file AlgorithmicReverb.h.

◆ bassCrossover_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::bassCrossover_ { T(200) }
protected

Definition at line 1071 of file AlgorithmicReverb.h.

◆ bassDecayMult_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::bassDecayMult_ { T(1.2) }
protected

Definition at line 1069 of file AlgorithmicReverb.h.

◆ bassLPCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::bassLPCoeff_ = T(0.026)
protected

Definition at line 1103 of file AlgorithmicReverb.h.

◆ bassRatio_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::bassRatio_ {}
protected

Definition at line 946 of file AlgorithmicReverb.h.

◆ bassState_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::bassState_ {}
protected

Definition at line 947 of file AlgorithmicReverb.h.

◆ cachedParams_

template<FloatType T>
CachedParams dspark::AlgorithmicReverb< T >::cachedParams_ {}
protected

Definition at line 1234 of file AlgorithmicReverb.h.

◆ ctrlPhase_

template<FloatType T>
int dspark::AlgorithmicReverb< T >::ctrlPhase_ = 0
protected

Definition at line 993 of file AlgorithmicReverb.h.

◆ damping_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::damping_ { T(0.5) }
protected

Definition at line 1056 of file AlgorithmicReverb.h.

◆ dcCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::dcCoeff_ = T(0.003)
protected

Definition at line 1104 of file AlgorithmicReverb.h.

◆ dcZ_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::dcZ_ {}
protected

Definition at line 950 of file AlgorithmicReverb.h.

◆ decayTime_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::decayTime_ { T(1) }
protected

Definition at line 1054 of file AlgorithmicReverb.h.

◆ diffBufs_

template<FloatType T>
std::array<RingBuffer<T>, kDiffStages> dspark::AlgorithmicReverb< T >::diffBufs_
protected

Definition at line 997 of file AlgorithmicReverb.h.

◆ diffCoeffs_

template<FloatType T>
std::array<T, kDiffStages> dspark::AlgorithmicReverb< T >::diffCoeffs_ {}
protected

Definition at line 999 of file AlgorithmicReverb.h.

◆ diffDelays_

template<FloatType T>
std::array<int, kDiffStages> dspark::AlgorithmicReverb< T >::diffDelays_ {}
protected

Definition at line 998 of file AlgorithmicReverb.h.

◆ diffuserStep2_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::diffuserStep2_
protected

Definition at line 1007 of file AlgorithmicReverb.h.

◆ diffuserStep2Delays_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::diffuserStep2Delays_ {}
protected

Definition at line 1008 of file AlgorithmicReverb.h.

◆ diffusion_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::diffusion_ { T(0.7) }
protected

Definition at line 1057 of file AlgorithmicReverb.h.

◆ earlyLevel_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::earlyLevel_ { T(1) }
protected

Definition at line 1063 of file AlgorithmicReverb.h.

◆ eco_

template<FloatType T>
bool dspark::AlgorithmicReverb< T >::eco_ = false
protected

Definition at line 988 of file AlgorithmicReverb.h.

◆ erAbsCoeffs_

template<FloatType T>
std::array<T, kMaxERTaps> dspark::AlgorithmicReverb< T >::erAbsCoeffs_ {}
protected

Definition at line 1021 of file AlgorithmicReverb.h.

◆ erBuf_

template<FloatType T>
RingBuffer<T> dspark::AlgorithmicReverb< T >::erBuf_
protected

Definition at line 1018 of file AlgorithmicReverb.h.

◆ erGainsL_

template<FloatType T>
std::array<T, kMaxERTaps> dspark::AlgorithmicReverb< T >::erGainsL_ {}
protected

Definition at line 1020 of file AlgorithmicReverb.h.

◆ erGainsR_

template<FloatType T>
std::array<T, kMaxERTaps> dspark::AlgorithmicReverb< T >::erGainsR_ {}
protected

Definition at line 1020 of file AlgorithmicReverb.h.

◆ erLPStateL_

template<FloatType T>
std::array<T, kMaxERTaps> dspark::AlgorithmicReverb< T >::erLPStateL_ {}
protected

Definition at line 1022 of file AlgorithmicReverb.h.

◆ erLPStateR_

template<FloatType T>
std::array<T, kMaxERTaps> dspark::AlgorithmicReverb< T >::erLPStateR_ {}
protected

Definition at line 1023 of file AlgorithmicReverb.h.

◆ erTapsL_

template<FloatType T>
std::array<int, kMaxERTaps> dspark::AlgorithmicReverb< T >::erTapsL_ {}
protected

Definition at line 1019 of file AlgorithmicReverb.h.

◆ erTapsR_

template<FloatType T>
std::array<int, kMaxERTaps> dspark::AlgorithmicReverb< T >::erTapsR_ {}
protected

Definition at line 1019 of file AlgorithmicReverb.h.

◆ erToLateBuf_

template<FloatType T>
RingBuffer<T> dspark::AlgorithmicReverb< T >::erToLateBuf_
protected

Definition at line 1031 of file AlgorithmicReverb.h.

◆ erToLateMs_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::erToLateMs_ { T(0) }
protected

Definition at line 1061 of file AlgorithmicReverb.h.

◆ erToLateSamples_

template<FloatType T>
std::atomic<int> dspark::AlgorithmicReverb< T >::erToLateSamples_ { 0 }
protected

Definition at line 1032 of file AlgorithmicReverb.h.

◆ fbAPBufsA_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::fbAPBufsA_
protected

Definition at line 953 of file AlgorithmicReverb.h.

◆ fbAPBufsB_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::fbAPBufsB_
protected

Definition at line 954 of file AlgorithmicReverb.h.

◆ fbAPCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::fbAPCoeff_ = T(0.6)
protected

Definition at line 957 of file AlgorithmicReverb.h.

◆ fbAPDelaysA_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::fbAPDelaysA_ {}
protected

Definition at line 955 of file AlgorithmicReverb.h.

◆ fbAPDelaysB_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::fbAPDelaysB_ {}
protected

Definition at line 956 of file AlgorithmicReverb.h.

◆ fbSmooth_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::fbSmooth_ = T(0.3)
protected

Definition at line 970 of file AlgorithmicReverb.h.

◆ fdnDelayLens_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::fdnDelayLens_ {}
protected

Definition at line 933 of file AlgorithmicReverb.h.

◆ fdnDelays_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::fdnDelays_
protected

Definition at line 932 of file AlgorithmicReverb.h.

◆ highCrossover_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::highCrossover_ { T(5000) }
protected

Definition at line 1070 of file AlgorithmicReverb.h.

◆ highDecayMult_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::highDecayMult_ { T(0.5) }
protected

Definition at line 1068 of file AlgorithmicReverb.h.

◆ intAPBufsA_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::intAPBufsA_
protected

Definition at line 960 of file AlgorithmicReverb.h.

◆ intAPBufsB_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::intAPBufsB_
protected

Definition at line 961 of file AlgorithmicReverb.h.

◆ intAPCoeff_

template<FloatType T>
constexpr T dspark::AlgorithmicReverb< T >::intAPCoeff_ = T(0.5)
staticconstexprprotected

Definition at line 964 of file AlgorithmicReverb.h.

◆ intAPDelaysA_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::intAPDelaysA_ {}
protected

Definition at line 962 of file AlgorithmicReverb.h.

◆ intAPDelaysB_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::intAPDelaysB_ {}
protected

Definition at line 963 of file AlgorithmicReverb.h.

◆ kBaseDelaysMs_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kBaseDelaysMs_[kFDNSize]
staticconstexprprotected
Initial value:
= {
29.7, 34.1, 39.3, 45.2, 52.0, 58.1, 64.9, 72.3,
80.4, 89.0, 98.3, 108.7, 119.9, 132.3, 145.7, 160.1
}

Definition at line 817 of file AlgorithmicReverb.h.

◆ kDiffBaseCoeffs_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kDiffBaseCoeffs_[kDiffStages]
staticconstexprprotected
Initial value:
= {
0.75, 0.75, 0.72, 0.72, 0.70, 0.70, 0.68, 0.68
}

Definition at line 827 of file AlgorithmicReverb.h.

◆ kDiffDelaysMs_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kDiffDelaysMs_[kDiffStages]
staticconstexprprotected
Initial value:
= {
1.03, 1.47, 2.19, 3.13, 4.23, 5.59, 7.19, 9.47
}

Definition at line 823 of file AlgorithmicReverb.h.

◆ kDiffStages

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kDiffStages = 8
staticconstexprprotected

Definition at line 779 of file AlgorithmicReverb.h.

◆ kDiffuserStep2Ms_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kDiffuserStep2Ms_[kFDNSize]
staticconstexprprotected
Initial value:
= {
15.7, 17.9, 20.1, 22.3, 24.7, 26.9, 29.3, 31.1,
33.7, 35.3, 37.1, 39.3, 41.1, 42.9, 44.3, 45.7
}

Definition at line 845 of file AlgorithmicReverb.h.

◆ kEcoCtrlInterval

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kEcoCtrlInterval = 16
staticconstexprprotected

modulation refresh period (samples)

Definition at line 786 of file AlgorithmicReverb.h.

◆ kEcoERTaps

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kEcoERTaps = 12
staticconstexprprotected

early-reflection tap cap in Eco

Definition at line 787 of file AlgorithmicReverb.h.

◆ kEcoLines

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kEcoLines = 8
staticconstexprprotected

FDN lines in Eco quality.

Definition at line 785 of file AlgorithmicReverb.h.

◆ kFbAPRatioA_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kFbAPRatioA_ = 0.25
staticconstexprprotected

Definition at line 835 of file AlgorithmicReverb.h.

◆ kFbAPRatioB_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kFbAPRatioB_ = 0.35
staticconstexprprotected

Definition at line 836 of file AlgorithmicReverb.h.

◆ kFbAPStages

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kFbAPStages = 2
staticconstexprprotected

Definition at line 832 of file AlgorithmicReverb.h.

◆ kFDNSize

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kFDNSize = 16
staticconstexprprotected

Definition at line 778 of file AlgorithmicReverb.h.

◆ kInputGain

template<FloatType T>
constexpr T dspark::AlgorithmicReverb< T >::kInputGain = T(1) / T(8)
staticconstexprprotected

Definition at line 789 of file AlgorithmicReverb.h.

◆ kIntAPRatioA_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kIntAPRatioA_ = 0.15
staticconstexprprotected

Definition at line 965 of file AlgorithmicReverb.h.

◆ kIntAPRatioB_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kIntAPRatioB_ = 0.20
staticconstexprprotected

Definition at line 966 of file AlgorithmicReverb.h.

◆ kMaxERTaps

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kMaxERTaps = 40
staticconstexprprotected

Definition at line 780 of file AlgorithmicReverb.h.

◆ kMultiTapFracL_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kMultiTapFracL_[kNumMultiTaps] = {0.37, 0.67, 0.23, 0.81, 0.44, 0.59, 0.31}
staticconstexprprotected

Definition at line 811 of file AlgorithmicReverb.h.

◆ kMultiTapFracR_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kMultiTapFracR_[kNumMultiTaps] = {0.43, 0.71, 0.29, 0.63, 0.47, 0.53, 0.37}
staticconstexprprotected

Definition at line 812 of file AlgorithmicReverb.h.

◆ kMultiTapLineL_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kMultiTapLineL_[kNumMultiTaps] = {0, 2, 5, 7, 9, 12, 14}
staticconstexprprotected

Definition at line 809 of file AlgorithmicReverb.h.

◆ kMultiTapLineR_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kMultiTapLineR_[kNumMultiTaps] = {1, 3, 4, 8, 10, 13, 15}
staticconstexprprotected

Definition at line 810 of file AlgorithmicReverb.h.

◆ kMultiTapSignL_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kMultiTapSignL_[kNumMultiTaps] = {+1, -1, +1, -1, +1, -1, +1}
staticconstexprprotected

Definition at line 813 of file AlgorithmicReverb.h.

◆ kMultiTapSignR_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kMultiTapSignR_[kNumMultiTaps] = {+1, +1, -1, +1, -1, +1, -1}
staticconstexprprotected

Definition at line 814 of file AlgorithmicReverb.h.

◆ kNumMultiTaps

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kNumMultiTaps = 7
staticconstexprprotected

Definition at line 781 of file AlgorithmicReverb.h.

◆ kOutDiffDelaysMsL_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kOutDiffDelaysMsL_[kOutDiffStages] = {1.47, 2.31}
staticconstexprprotected

Definition at line 851 of file AlgorithmicReverb.h.

◆ kOutDiffDelaysMsR_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kOutDiffDelaysMsR_[kOutDiffStages] = {1.63, 2.47}
staticconstexprprotected

Definition at line 852 of file AlgorithmicReverb.h.

◆ kOutDiffStages

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kOutDiffStages = 2
staticconstexprprotected

Definition at line 782 of file AlgorithmicReverb.h.

◆ kOutputNorm

template<FloatType T>
constexpr T dspark::AlgorithmicReverb< T >::kOutputNorm = T(1) / T(5.0)
staticconstexprprotected

Definition at line 792 of file AlgorithmicReverb.h.

◆ kOutputNormEco

template<FloatType T>
constexpr T dspark::AlgorithmicReverb< T >::kOutputNormEco = T(0.32)
staticconstexprprotected

Definition at line 796 of file AlgorithmicReverb.h.

◆ kOutSignL_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kOutSignL_[kFDNSize]
staticconstexprprotected
Initial value:
= {
1, -1, 1, 1, -1, 1, -1, -1,
1, -1, -1, 1, -1, 1, 1, -1
}

Definition at line 799 of file AlgorithmicReverb.h.

◆ kOutSignR_

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kOutSignR_[kFDNSize]
staticconstexprprotected
Initial value:
= {
1, 1, -1, 1, 1, -1, -1, -1,
-1, 1, -1, 1, -1, -1, 1, 1
}

Definition at line 803 of file AlgorithmicReverb.h.

◆ kParAPDelaysMs_

template<FloatType T>
constexpr double dspark::AlgorithmicReverb< T >::kParAPDelaysMs_[kFDNSize]
staticconstexprprotected
Initial value:
= {
5.3, 6.1, 7.1, 7.9, 8.9, 9.7, 10.7, 11.7,
12.3, 13.3, 14.3, 15.1, 16.1, 17.1, 18.1, 19.1
}

Definition at line 839 of file AlgorithmicReverb.h.

◆ kPrimeTableMax

template<FloatType T>
constexpr int dspark::AlgorithmicReverb< T >::kPrimeTableMax = 131072
staticconstexprprotected

Definition at line 1872 of file AlgorithmicReverb.h.

◆ lateLevel_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::lateLevel_ { T(1) }
protected

Definition at line 1064 of file AlgorithmicReverb.h.

◆ mix_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::mix_ { T(0.3) }
protected

Definition at line 1062 of file AlgorithmicReverb.h.

◆ mixer_

template<FloatType T>
DryWetMixer<T> dspark::AlgorithmicReverb< T >::mixer_
protected

Definition at line 1041 of file AlgorithmicReverb.h.

◆ modACache_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::modACache_ {}
protected

Definition at line 990 of file AlgorithmicReverb.h.

◆ modBCache_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::modBCache_ {}
protected

Definition at line 991 of file AlgorithmicReverb.h.

◆ modDepth_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::modDepth_ { T(0.1) }
protected

Definition at line 1058 of file AlgorithmicReverb.h.

◆ modDepthA_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::modDepthA_ { T(1) }
protected

Definition at line 1105 of file AlgorithmicReverb.h.

◆ modDepthB_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::modDepthB_ { T(0.5) }
protected

Definition at line 1106 of file AlgorithmicReverb.h.

◆ modLFOA_

template<FloatType T>
std::array<SmoothRandomLFO, kFDNSize> dspark::AlgorithmicReverb< T >::modLFOA_
protected

Definition at line 973 of file AlgorithmicReverb.h.

◆ modLFOB_

template<FloatType T>
std::array<SmoothRandomLFO, kFDNSize> dspark::AlgorithmicReverb< T >::modLFOB_
protected

Definition at line 974 of file AlgorithmicReverb.h.

◆ modRate_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::modRate_ { T(1) }
protected

Definition at line 1059 of file AlgorithmicReverb.h.

◆ nLines_

template<FloatType T>
int dspark::AlgorithmicReverb< T >::nLines_ = kFDNSize
protected

Definition at line 989 of file AlgorithmicReverb.h.

◆ noiseCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::noiseCoeff_ = T(0)
protected

Definition at line 982 of file AlgorithmicReverb.h.

◆ noiseCoeffEco_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::noiseCoeffEco_ = T(0)
protected

Definition at line 994 of file AlgorithmicReverb.h.

◆ noiseDepth_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::noiseDepth_ = T(0)
protected

Definition at line 983 of file AlgorithmicReverb.h.

◆ noiseLP_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::noiseLP_ = T(0)
protected

Definition at line 981 of file AlgorithmicReverb.h.

◆ noiseND_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::noiseND_ = T(0)
protected

Definition at line 992 of file AlgorithmicReverb.h.

◆ noiseState_

template<FloatType T>
uint32_t dspark::AlgorithmicReverb< T >::noiseState_ = 1
protected

Definition at line 980 of file AlgorithmicReverb.h.

◆ numERTaps_

template<FloatType T>
int dspark::AlgorithmicReverb< T >::numERTaps_ = 0
protected

Definition at line 1024 of file AlgorithmicReverb.h.

◆ outDiffBufsL_

template<FloatType T>
std::array<RingBuffer<T>, kOutDiffStages> dspark::AlgorithmicReverb< T >::outDiffBufsL_
protected

Definition at line 1011 of file AlgorithmicReverb.h.

◆ outDiffBufsR_

template<FloatType T>
std::array<RingBuffer<T>, kOutDiffStages> dspark::AlgorithmicReverb< T >::outDiffBufsR_
protected

Definition at line 1012 of file AlgorithmicReverb.h.

◆ outDiffCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::outDiffCoeff_ = T(0.45)
protected

Definition at line 1015 of file AlgorithmicReverb.h.

◆ outDiffDelaysL_

template<FloatType T>
std::array<int, kOutDiffStages> dspark::AlgorithmicReverb< T >::outDiffDelaysL_ {}
protected

Definition at line 1013 of file AlgorithmicReverb.h.

◆ outDiffDelaysR_

template<FloatType T>
std::array<int, kOutDiffStages> dspark::AlgorithmicReverb< T >::outDiffDelaysR_ {}
protected

Definition at line 1014 of file AlgorithmicReverb.h.

◆ paramsDirty_

template<FloatType T>
std::atomic<bool> dspark::AlgorithmicReverb< T >::paramsDirty_ { false }
protected

Definition at line 1077 of file AlgorithmicReverb.h.

◆ parAPBufs_

template<FloatType T>
std::array<RingBuffer<T>, kFDNSize> dspark::AlgorithmicReverb< T >::parAPBufs_
protected

Definition at line 1002 of file AlgorithmicReverb.h.

◆ parAPCoeff_

template<FloatType T>
T dspark::AlgorithmicReverb< T >::parAPCoeff_ = T(0.65)
protected

Definition at line 1004 of file AlgorithmicReverb.h.

◆ parAPDelays_

template<FloatType T>
std::array<int, kFDNSize> dspark::AlgorithmicReverb< T >::parAPDelays_ {}
protected

Definition at line 1003 of file AlgorithmicReverb.h.

◆ preDelayBuf_

template<FloatType T>
RingBuffer<T> dspark::AlgorithmicReverb< T >::preDelayBuf_
protected

Definition at line 1027 of file AlgorithmicReverb.h.

◆ preDelayMs_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::preDelayMs_ { T(0) }
protected

Definition at line 1060 of file AlgorithmicReverb.h.

◆ preDelaySamples_

template<FloatType T>
std::atomic<int> dspark::AlgorithmicReverb< T >::preDelaySamples_ { 0 }
protected

Definition at line 1028 of file AlgorithmicReverb.h.

◆ presetDirty_

template<FloatType T>
std::atomic<bool> dspark::AlgorithmicReverb< T >::presetDirty_ { false }
protected

Definition at line 1076 of file AlgorithmicReverb.h.

◆ prevFeedback_

template<FloatType T>
std::array<T, kFDNSize> dspark::AlgorithmicReverb< T >::prevFeedback_ {}
protected

Definition at line 969 of file AlgorithmicReverb.h.

◆ quality_

template<FloatType T>
std::atomic<Quality> dspark::AlgorithmicReverb< T >::quality_ { Quality::Full }
protected

Definition at line 1073 of file AlgorithmicReverb.h.

◆ qualityDirty_

template<FloatType T>
std::atomic<bool> dspark::AlgorithmicReverb< T >::qualityDirty_ { false }
protected

Definition at line 1097 of file AlgorithmicReverb.h.

◆ size_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::size_ { T(0.5) }
protected

Definition at line 1055 of file AlgorithmicReverb.h.

◆ spec_

template<FloatType T>
AudioSpec dspark::AlgorithmicReverb< T >::spec_ {}
protected

Definition at line 929 of file AlgorithmicReverb.h.

◆ toneDirty_

template<FloatType T>
std::atomic<bool> dspark::AlgorithmicReverb< T >::toneDirty_ { false }
protected

Definition at line 1096 of file AlgorithmicReverb.h.

◆ toneHighCutHz_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::toneHighCutHz_ { T(-1) }
protected

Definition at line 1099 of file AlgorithmicReverb.h.

◆ toneHPActive_

template<FloatType T>
bool dspark::AlgorithmicReverb< T >::toneHPActive_ = false
protected

Definition at line 1038 of file AlgorithmicReverb.h.

◆ toneHPBiquad_

template<FloatType T>
Biquad<T, 2> dspark::AlgorithmicReverb< T >::toneHPBiquad_
protected

Definition at line 1036 of file AlgorithmicReverb.h.

◆ toneLowCutHz_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::toneLowCutHz_ { T(-1) }
protected

Definition at line 1098 of file AlgorithmicReverb.h.

◆ toneLPActive_

template<FloatType T>
bool dspark::AlgorithmicReverb< T >::toneLPActive_ = false
protected

Definition at line 1037 of file AlgorithmicReverb.h.

◆ toneLPBiquad_

template<FloatType T>
Biquad<T, 2> dspark::AlgorithmicReverb< T >::toneLPBiquad_
protected

Definition at line 1035 of file AlgorithmicReverb.h.

◆ type_

template<FloatType T>
std::atomic<Type> dspark::AlgorithmicReverb< T >::type_ { Type::Room }
protected

Definition at line 1053 of file AlgorithmicReverb.h.

◆ userParamMask_

template<FloatType T>
std::atomic<uint32_t> dspark::AlgorithmicReverb< T >::userParamMask_ { 0u }
protected

Definition at line 1093 of file AlgorithmicReverb.h.

◆ width_

template<FloatType T>
std::atomic<T> dspark::AlgorithmicReverb< T >::width_ { T(1) }
protected

Definition at line 1065 of file AlgorithmicReverb.h.


The documentation for this class was generated from the following file: