|
arduino-audio-tools
|
Sound Generators. More...
Classes | |
| class | FastIntSineGenerator< T > |
| Sine wave generator that does not use any floating point operations in the readSample() hot path: it advances a 32 bit phase accumulator with an integer increment and looks up the result in a Q15 fixed point table. All floating point math (converting frequency/sample_rate into the phase increment) is done once in setFrequency()/setAudioInfo(), never per sample. This makes it a good fit for MCUs without a hardware FPU - e.g. the RP2040 - where sinf() is comparatively expensive. More... | |
| class | FastSineGenerator< T > |
| Sine wave which is based on a fast approximation function using floating point math. More... | |
| class | FloatSineGenerator< T > |
| Generates a Sound with the help of sin() function. If performance is of concern, I suggest to use theSineFromTable, the FastSineGenerator or the FastIntSineGenerator. More... | |
| class | GeneratorFixedValue< T > |
| Just returns a constant value. More... | |
| class | GeneratorFromArray< T > |
| We generate the samples from an array which is provided in the constructor. More... | |
| class | GeneratorFromStream< T > |
| An Adapter Class which lets you use any Stream as a Generator. More... | |
| class | GeneratorMixer< T > |
| Generator which combines (mixes) multiple sound generators into one output. More... | |
| class | PinkNoiseGenerator< T > |
| Generates pink noise. More... | |
| class | SawToothGenerator< T > |
| Generates a saw tooth wave sound. Uses a 32 bit phase accumulator with an integer increment, just like FastIntSineGenerator: no floating point operations or divisions in the readSample() hot path. Unlike a sine, a saw tooth needs no lookup table either - a wrapping unsigned accumulator reinterpreted as signed already is a linear ramp - so this is even cheaper than FastIntSineGenerator and a good fit for MCUs without a hardware FPU (e.g. RP2040), where the previous sinf()/float based implementation (inherited from SineGenerator) was comparatively expensive. More... | |
| class | SilenceGenerator< T > |
| Provides a fixed value (e.g. 0) as sound data. This can be used e.g. to test the output functionality which should optimally just output silence and no artifacts. More... | |
| class | SineFromTable< T > |
| A sine generator based on a table. The table is created using degrees where one full wave is 360 degrees. More... | |
| class | SoundGenerator< T > |
| Base class to define the abstract interface for the sound generating classes. More... | |
| class | SquareWaveGenerator< T > |
| Generates a square wave sound. Uses the same 32 bit phase accumulator as SawToothGenerator/FastIntSineGenerator: no floating point operations or sin() calls in the readSample() hot path. A square wave needs neither a sine approximation nor a lookup table - just the sign bit of the ramp - so readSample() is a single comparison, making this a good fit for MCUs without a hardware FPU (e.g. RP2040), where the previous FastSineGenerator based implementation still did a float polynomial evaluation per sample just to keep its sign. More... | |
| class | STKGenerator< StkCls, T > |
| The Synthesis ToolKit in C++ (STK) is a set of open source audio signal processing and algorithmic synthesis classes written in the C++ programming language. You need to install https://github.com/pschatzmann/Arduino-STK. More... | |
| class | Synthesizer |
| A simple Synthesizer which can generate sound having multiple keys pressed. The main purpose of this class is managing the synthezizer channels. More... | |
| class | TestGenerator< T > |
| Generates a test signal which is easy to check because the values are incremented or decremented by 1. More... | |
| class | WhiteNoiseGenerator< T > |
| Generates a random noise sound with the help of rand() function. More... | |
Sound Generators.