A tiny synthesizer to make saws. Desktop app for linux, written in C++ with Qt and Port Audio.
- Qt 5
- Port Audio
To build this project just open the file src/TinySaw.pro in QtCreator and build it.
If there is no output just restart Pulse Audio with
pulseaudio --kill
The code is divided in two parts :
- MainWindow : Handles window and key events
- audio : The file managing the audio synthesis from a low level
- input : The file containing all input events triggered from graphics
- AudioHandler : Handles audio components
- SoundGenerator : Manages all voices, the mixer and the oscillator
- Oscillator : Provides sound wave's shape
- NoteHandler : Gathers all voices for one note event
- Mixer : Handles the volume of a key handler
- Voice : Generates the sound for one frequency
Here is a small diagram, legend :
- +-> Interracts with
- +-- Belongs to
Input (Keyboard / Midi)
+-> input
+-> AudioHandler
+-> SoundGenerator
+-- Oscillator
+-- Mixer
+-- NoteHandlers
+-- Voices
+-> Output (Speakers / File)