YSE sound engine
1.0
cross platform sound engine
|
Public Member Functions | |
delay & | setSize (UInt size) |
delay & | process (AUDIOBUFFER &buffer) |
delay & | read (sample &result, UInt delayTime) |
delay & | read (sample &result, AUDIOBUFFER &delayTime) |
delay (Int size) | |
delay (const delay &) | |
Delay keeps an internal delay line of variable length.
You can read from a delay at any given position, which enables you to get a delayed buffer as a result.
YSE::DSP::delay::delay | ( | Int | size | ) |
Create a delay line.
size | The initial length of the delay line. This can be changed afterwards, but it's faster if you provide the correct size when creating the object. |
delay& YSE::DSP::delay::setSize | ( | UInt | size | ) |
Changes the length of the delay line.
Longer delay lines use more memory, but allow for longer delays.
size | the size of the delay line. |
delay& YSE::DSP::delay::process | ( | AUDIOBUFFER & | buffer | ) |
Process is responsible for updating the internal delay buffer.
It should only be called once, during audio processing.
buffer | the audio buffer to store in the delay buffer. |
Read from the delay at a fixed point and store the required part of the buffer in result.
result | This buffer will receive the audio read from the delay. |
delayTime | The frame at which to start reading from the delay line. |
Read from the delay at a variable point and store the required part of the buffer in result.
result | This buffer will receive the audio read from the delay. |
delayTime | A buffer containing the delay time for each frame. |