A WavePacket which allows a custom table to be set as the audio source for the wavepackets (or grains). More...
#include <WavePacketSample.h>
A WavePacket which allows a custom table to be set as the audio source for the wavepackets (or grains).
ALGORITHM | options are SINGLE or DOUBLE, for a single non-overlapping stream of packets or a double, overlapping stream. |
Definition at line 23 of file WavePacketSample.h.
Public Member Functions | |
void | setTable (const int8_t *TABLE_NAME) |
Change the sound table which will be played. More... | |
void | set (int fundamental, int bandwidth, int centrefreq) |
Set all the parameters for the synthesis. More... | |
void | setFundamental (int fundamental) |
Set the fundamental frequency. More... | |
void | setBandwidth (int bandwidth) |
Set the bandwidth. More... | |
void | setCentreFreq (int centrefreq) |
Set the centre frequency. More... | |
int | next () |
Calculate the next synthesised sample. More... | |
|
inlineinherited |
Calculate the next synthesised sample.
Definition at line 113 of file WavePacket.h.
|
inlineinherited |
Set all the parameters for the synthesis.
The function is designed so that usable ranges for parameters can come from analog inputs, ie. 0-1023.
fundamental | the rate at which packets are produced. |
bandwidth | the width of each packet. A lower value allows more of the centre frequency to be audible, a rounder sound. A higher value produces narrower packets, a more buzzing sound. |
centrefreq | the oscillation frequency within each packet. |
Definition at line 57 of file WavePacket.h.
|
inlineinherited |
Set the bandwidth.
The function is designed so that usable ranges for parameters can come from analog inputs, ie. 0-1023.
bandwidth | the width of each packet. A lower value allows more of the centre frequency to be audible, a rounder sound. A higher value produces narrower packets, a more buzzing sound. |
Definition at line 85 of file WavePacket.h.
|
inlineinherited |
Set the centre frequency.
The function is designed so that usable ranges for parameters can come from analog inputs, ie. 0-1023.
centrefreq | the oscillation frequency within each packet. |
Definition at line 100 of file WavePacket.h.
|
inlineinherited |
Set the fundamental frequency.
The function is designed so that usable ranges for parameters can come from analog inputs, ie. 0-1023.
fundamental | the rate at which packets are produced. |
Definition at line 70 of file WavePacket.h.
|
inline |
Change the sound table which will be played.
Needs to be 8192 cells long for now.
TABLE_NAME | is the name of the array in the table ".h" file you're using. |
Definition at line 30 of file WavePacketSample.h.