Skip to content

Software synthesizer written in C++, using SDL 2 for its audio backend.

Notifications You must be signed in to change notification settings

airloaf/VSSynth

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Audio synthesizer library for SDL2. Written in C++.

Features

  • Primitive waveforms (Sine, Square, Sawtooth, Triangle, Noise)
  • ADSR (Attack Decay Sustain Release) envelopes
  • Polyphony
  • WAV file output
  • LFO (Low Frequency Oscillation)
  • Sequencer
  • Sample synth patches (Guitar, Piano, Glockenspiel, etc.)
  • Volume control

Use Cases

There are many things you could possibly make with VSSynth!

  • Chiptune playback/composition
  • Digital Keyboard
  • Retro console emulators (NES, Genesis, Atari, Chip-8 interpreter)
  • Video games (Mario Paint, Minecraft Note Block)

Dependencies

  • CMake (Version 3.9 is specified, but lower versions will probably work fine)
  • SDL2

How to build

Use the accompanying CMakeLists.txt to generate your project. You will need to change some of the variables to reflect your development environment.

The CMake files will generate a library called "VSSynth", which you should link to your executables. CMake can also generate some examples as listed below.

Examples

Example Description
Simple Tone The "Hello World!" of VSSynth. Produces a Sine Wave with the note C4.
Low Frequency Oscillator Produces a Sawtooth Wave with a low frequency oscillator attached.
Record Tone Produces a WAVE file with a Sine Wave with the note C4.
Piano A piano which can play notes on keyboard input.
Sequenced Beat Extension of the Piano example. The song, "Mary had a little lamb", will play on repeat in the background while you control the piano.
MIDI Player A MIDI player using synthesized instruments included with VSSynth. Does not fully support all MIDI messages, but the majority of songs play well on this.

Resources