Skip to main content

PmWaveTail

Type Alias PmWaveTail 

Source
pub type PmWaveTail = [[f32; 32]; 2];
Expand description

Slots NUM_WAVEFORM_SAMPLES..PM_WAVE_POINTS of projectM’s per-channel wave buffers (WaveformMath::m_pcmDataL/R).

The buffers are members of the preset’s WaveformMath object and every frame only the first 480 slots are overwritten with fresh samples; the IIR smoothing then runs over all 512 slots in place, so the last 32 slots keep the previous frame’s smoothed values as their “input” (s[i] = s[i]*mix1 + s[i-1]*mix2 with the old s[i]). Modes that read buf[i + 32] for i >= 448 (1, 2, 3, 5, 12, 15, …) see that state. Zero at preset load.