Mozzi  version v1.1.0
sound synthesis library for Arduino
WaveFolder< T > Class Template Reference

A simple wavefolder. More...

#include <WaveFolder.h>

Public Member Functions

 WaveFolder ()
 Constructor.
 
void setHighLimit (T highLimit)
 Set the high limit where the wave will start to be folded back the other way. More...
 
void setLowLimit (T lowLimit)
 Set the low limit where the wave will start to be folded back the other way. More...
 
void setLimits (T lowLimit, T highLimit)
 Set the low and the high limits at the same time. More...
 
next (T in)
 Return the next folded sample. More...
 

Detailed Description

template<typename T = AudioOutputStorage_t>
class WaveFolder< T >

A simple wavefolder.

Definition at line 38 of file WaveFolder.h.

Member Function Documentation

◆ next()

template<typename T = AudioOutputStorage_t>
T WaveFolder< T >::next ( in)
inline

Return the next folded sample.

Parameters
inis the signal input.
Returns
the folded output.

Definition at line 86 of file WaveFolder.h.

◆ setHighLimit()

template<typename T = AudioOutputStorage_t>
void WaveFolder< T >::setHighLimit ( highLimit)
inline

Set the high limit where the wave will start to be folded back the other way.

Parameters
highLimitthe high limit used by the wavefolder.

Definition at line 49 of file WaveFolder.h.

◆ setLimits()

template<typename T = AudioOutputStorage_t>
void WaveFolder< T >::setLimits ( lowLimit,
highLimit 
)
inline

Set the low and the high limits at the same time.

Parameters
lowLimitthe low limit used by the wavefolder
highLimitthe high limit used by the wavefolder
Note
highLimit MUST be higher than lowLimit

Definition at line 73 of file WaveFolder.h.

◆ setLowLimit()

template<typename T = AudioOutputStorage_t>
void WaveFolder< T >::setLowLimit ( lowLimit)
inline

Set the low limit where the wave will start to be folded back the other way.

Parameters
lowLimitthe low limit used by the wavefolder.

Definition at line 60 of file WaveFolder.h.