Welcome to the simplest textual synthesizer.
> dac $ osc 440
Csound-expression is a Haskell framework for computer music. With the help of the library we can create our instruments on the fly. A few lines in the interpreter is enough to get the cool sound going out of your speakers. It can be used for simple daily sound-file processing or for a full-blown live performances. It's available on Hackage.
Let's look at how we can create computer music with Haskell.
Appendix:
WARNING: the library works best within ghci. The real-time sound rendering
function dac
spawns a child process in the background which may continue
to execute after you stop the main process that runs the programm.
It's not so in vim but it happens in the Sublime Editor and when you
invoke runhaskell
. So the best is to write you program in the separate
file and then load it in the ghci and invoke the function main
(which runs the sound rendering with the function dac
).