Tonbandfetzen is a collection of command-line tools that allow you to compose music based on audio fragments generated from plain text input. It contains:
tz mel
- generate sound fragments from plain texttz guitar
- read guitar tablaturetz stick
- concatenate audio datatz stack
- superimpose audio datatz stretch
- rescale audio datatz repeat
- loop audio datatz trim
- strip leading and trailing silencetz mono
- unzip audio channelstz harmonics
- show spectra of wave samplestz inspect
- show information on audio filetz riff2aiff
- convert .wav(e) into .aif(f) filestz aiff2riff
- convert .aif(f) into .wav(e) filestz tag
- add ID3v2 metadata to .wav(e) fileszplay
- generate and play sound fragments
Different task are spread across separate executables, which communicate via
files in the Waveform Audio File Format (.wav). Hence, the composition process
can be controlled using build-automation software, allowing for partial updates
and parallel execution (make -j
).
At the heart of this toolbox, the program mel
converts text into audio (try
here):
echo "T pyth M A2'8 W ,5 A2' A3' E4' A4' C#v5' E5' Gz5' A5'" | tz mel | aplay
The guitar
preprocessor converts tablature into suitable mel
input:
echo "X synth |3
E4|--------------------0~~~~~~~~~~~|~~~~0~~~~~~~~~~~~~~~~~~~~~~~~~~~|
B3|----0~~~~~~~~~~~~~3~~~0~~~~~0~~~|~~3~~~0~~~~~0~~~~~~~~~~~~~~~~~~~|
G3|--2~~~0~~~~~0~~~~~~~~~~~~~2~~~0~|~~~~~~~~~~2~~~0~~~~~0~~~~~~~~~~~|
D3|----------2~~~0~~~~~~~~~~~~~~~~~|~~~~~~~~~~~~~~~~~~2~~~0~~~~~0~~~|
A2|3~~~~~~~~~~~~~~~----------------|--------------------------2~~~0~|
E2|----------------3~~~~~~~~~~~~~~~|0~~~~~~~~~~~~~~~2~~~~~~~3~~~~~~~|
" | tz guitar | tz mel | tz repeat | aplay
The Functional Just System for just intonation invented by misotanni is partially supported.
To build all tools, you only need a recent Fortran compiler:
cd /path/to/Tonbandfetzen
make FC=gfortran FFLAGS=-O3
To make the tools and documentation accessible, consider adding the following lines to your .bashrc:
REPO=/path/to/Tonbandfetzen
export PATH=$REPO/bin:$PATH
export PERL5LIB=$REPO/perl/lib:$PERL5LIB
export MANPATH=$REPO/doc:$MANPATH
You might also want to link the Vim syntax and Bash completion files to the appropriate locations:
ln -s /path/to/Tonbandfetzen/config/syntax/tz.vim ~/.vim/syntax/
ln -s /path/to/Tonbandfetzen/config/completions/tz \
~/.local/share/bash-completion/completions/
To have Vim detect the corresponding file types, add this line to your .vimrc:
autocmd BufRead,BufNewFile *.mel,*.gtr setlocal filetype=tz
Please have a look at the examples, some of which require Python or eSpeak NG:
cd examples/freedom
make -j 2
aplay freedom.wav
Each program has its own manual page:
man tz mel
You can also listen to the examples and browse the manual pages here.
The name Tonbandfetzen originates from the song Explosion by Tocotronic from their 2007 album Kapitulation.
Have a look at ForSynth by Vincent Magnin.