The first result of my recent foray into Nim audio programming!
What can I say, it's even more awesome than I noticed.
I'm a former SuperCollider audio programming language user. Starting out it was mind-blowing to be able to use code, but the language's many flaws and limitations really added up and now Nim spoiled me so much I decided to re-implement everything I do in Nim.
It's been a a joy. The code is so concise you can have the same birds-eye view as in audio programming languages, but you can super easily loop over an array of samples if you need to. Finally- full control over the data.
I started out transliterating a set of realtime FIR filters that were intended for embedded system use because they were so simple, and I think they sound pretty good- if you reduce the latency enough they distort and you get a kind of digital character, but you can get pretty transparent results with a little more.
I'm also working on a macro-based tool to connect to the jack audio server, some bandlimited oscillators, pre-calculated sweepable filters, and looking into porting some of the better OSS reverbs like Zita and maybe some Synthesis Toolkit (STK) tools. It seems to be pretty easy to have Faust integration as well, which is cool because they have some nice sounding stuff in their standard library.
It's really flexible because all these concepts that are complicated in other languages- input, port, ugen, whatever- it's all just an array of samples in Nim so I can just put out a bunch of tools that work on those and they go together.
I hope this is helpful!
Cool stuff!
While I'm working on ore examples for my nymph project, I am also implementing oscillators, filters and other stuff needed for audio plugins along the way. I'll have a look whether fur can safe me some work. :-)
Regarding the examples in the readme, what is the jill library? I couldn't find it in the nimble directory.
That’s awesome! Nim really is ideal for that sort of field.
One day you could try wrapping it in Figuro and making a simple GUI ahem. I’d be up for helping you and it’s easy to do 60fps animations and threading.
Also have you looked at @Treeform’s SIMD stuff for Pixie too? Seems like it might be handy.
Thank you!!!
It's funny I was thinking of naming the overall system 'nymph' because it sounds a bit like 'Nim' and 'synth'. I definitely like the way you think :)
jill is my upcoming Nimsih jack library (because "jack and jill went up the hill" so jill went up the hill... withJack. Get it? :D
I built jill on a futhark jack wrapper called jackfu but I'd overlooked your 'jacket' lib, I think I'm going to port it over so we don't duplicate effort. I intend to release it next week.
Yes it really shines in audio, even more than normal!
I plan on using Figuro for everything! :) It opens up Nim commercial audio plugin development. It's amazing. And this good performance without optimizing is great... Thank you for your kind offer!!!
Yeah the treeform array wrangling stuff is amazing, the flatty stuff was so good I had to steal it for limdb. His simd lib is definitely on my mind. I intend to get all components together for sound synthesis and then a recorder- and then optimize.
It's funny I was thinking of naming the overall system 'nymph' because it sounds a bit like 'Nim' and 'synth'. I definitely like the way you think :)
Not sure whether I've written this down before: why 'nymph'? well, it's an "elf too"!