wavelength 1.0.0
Loading...
Searching...
No Matches
effects.h
Go to the documentation of this file.
1#pragma once
2
5
10
12extern bool g_bMonoStream;
13
22short Saturate(short sample);
23
34short SoftClip(short sample, short threshold);
35
43
52void SetEffectParams(const EffectParams *params);
53
61
73 SampleBlock *inRight,
74 SampleBlock *outLeft,
75 SampleBlock *outRight);
76
89 SampleBlock *inRight,
90 SampleBlock *outLeft,
91 SampleBlock *outRight);
92
104 SampleBlock *inRight,
105 SampleBlock *outLeft,
106 SampleBlock *outRight);
107
119 SampleBlock *inRight,
120 SampleBlock *outLeft,
121 SampleBlock *outRight);
122
134 SampleBlock *inRight,
135 SampleBlock *outLeft,
136 SampleBlock *outRight);
137
149 SampleBlock *inRight,
150 SampleBlock *outLeft,
151 SampleBlock *outRight);
152
164 SampleBlock *inRight,
165 SampleBlock *outLeft,
166 SampleBlock *outRight);
167
179 SampleBlock *inRight,
180 SampleBlock *outLeft,
181 SampleBlock *outRight);
182
195 SampleBlock *inRight,
196 SampleBlock *outLeft,
197 SampleBlock *outRight,
198 short value);
199
207void SetStreamStatusAddress(void *address);
208
218int StreamData(void *data, int size);
219
231 SampleBlock *inRight,
232 SampleBlock *outLeft,
233 SampleBlock *outRight);
234
242
255 SampleBlock *inRight,
256 SampleBlock *outLeft,
257 SampleBlock *outRight);
258
271 SampleBlock *inRight,
272 SampleBlock *outLeft,
273 SampleBlock *outRight);
274
287 SampleBlock *inRight,
288 SampleBlock *outLeft,
289 SampleBlock *outRight);
290
302 SampleBlock *inRight,
303 SampleBlock *outLeft,
304 SampleBlock *outRight);
305
317 SampleBlock *inRight,
318 SampleBlock *outLeft,
319 SampleBlock *outRight);
Parameters of the effects for one channel, as the EE sends them.
Definition effectparams.h:17
bool g_bMonoStream
The effects.
void InitEffects()
Clear the delay line and the state of every effect.
void EffectDistortedFilter(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Run each channel through the resonant filter and clip loud output samples to full scale.
int StreamData(void *data, int size)
Append data to the stream, or end the stream and discard its contents when size is zero.
void EffectStutter(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Pass the input only on the samples where a phase accumulator advanced by the left level wraps,...
void InitLadderFilter()
Clear the ladder filter's state.
void EffectResonantFilter(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Run each channel through a resonant state variable low-pass filter.
void EffectTriangleWave(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Write a triangle test tone to both outputs.
void EffectSquareWave(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Write a square test tone to both outputs.
void EffectBypass(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Copy the inputs to the outputs.
short SoftClip(short sample, short threshold)
Pass a sample below threshold unchanged and saturate the part above it.
void EffectSilence(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Write silence to both outputs.
void EffectStream(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Play one block pair from the stream, or silence while the stream holds less than one pair.
void EffectTrackingEcho(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Echo the mono mix through two taps whose delays follow the time between runs of zero crossings.
void EffectConstant(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight, short value)
Write one value to every sample of both outputs.
void EffectNone(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Do nothing.
void EffectReverseSwap(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Write each input reversed to the other channel's output.
void EffectEcho(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Echo the mono mix through two taps of the delay line.
void EffectLadderFilter(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Run the mono mix through a four-stage ladder filter and a saturator, and step the current left parame...
void EffectMonoSweep(SampleBlock *inLeft, SampleBlock *inRight, SampleBlock *outLeft, SampleBlock *outRight)
Write the mono mix to both outputs, and step the current left parameters toward their targets.
void SetEffectParams(const EffectParams *params)
Make the target parameters current and store new targets.
void SetStreamStatusAddress(void *address)
Record the EE address that receives the stream's free space.
short Saturate(short sample)
Apply the cubic saturation curve to a sample, clamping beyond full scale.
void InitDelayLine()
Clear the delay line and the tracking echo's state.
One channel's block of 16-bit samples, the unit the effects and the transfers move.
Definition sampleblock.h:7