Mozzi  alpha 0.01.1t
sound synthesis library for Arduino
 All Classes Functions Typedefs
Public Member Functions
WaveShaper< char > Class Template Reference

char specialisation of WaveShaper template More...

List of all members.

Public Member Functions

 WaveShaper (const char *TABLE_NAME)
 Constructor.
char next (unsigned char in)
 Maps input to output, transforming it according to the table being used.

Detailed Description

template<>
class WaveShaper< char >

char specialisation of WaveShaper template

Definition at line 41 of file WaveShaper.h.


Constructor & Destructor Documentation

WaveShaper< char >::WaveShaper ( const char *  TABLE_NAME) [inline]

Constructor.

Use the template parameter to set type of numbers being mapped. For example, WaveShaper <int> myWaveShaper; makes a WaveShaper which uses ints.

Template Parameters:
TABLE_NAMEthe name of the table being used, which can be found in the ".h" file containing the table.

Definition at line 49 of file WaveShaper.h.


Member Function Documentation

char WaveShaper< char >::next ( unsigned char  in) [inline]

Maps input to output, transforming it according to the table being used.

Template Parameters:
inthe input signal. For flexibility, it's up to you to give the correct offset to your input signal. So if you'r mapping a signed 8-bit signal (such as the output of an Oscil) into a 256 cell table centred around cell 128, add 128 to offset the input value.
Returns:
the shaped signal.

Definition at line 63 of file WaveShaper.h.


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