qdunkan at gmail.com
Sat Aug 25 16:14:24 EDT 2007
> Indeed, you can write certain DSP algorithms beautifully in Haskell.
> Now, if only it could talk to the audio hardware... (Or just use common
> file formats even.)
Oh, that's easy. I wrote an FFI interface to portaudio a while back
to write a delay-looping type utility in haskell. It was pretty
trivial. You could do the same for libsndfile or whatever.
The only thing I'm uncertain about is whether it would have good
enough time and space performance. All the real work is writing yet
another set of basic envelope, oscillator, and fft primitives. You
*should* be able to go all the way down to the samples in pure haskell
though, which would be more elegant than those other languages :)
> Reaktor has abstraction. You can build a gizmo that does something
> useful, call it a macro, and then use it whereever you want.
Well, except that if you then change your macro you have re-copy it
into every instrument or ensemble or other macro that uses it. So I
consider the macros basically a copy and paste mechanism.
More information about the Haskell-Cafe