1
votes

I'm building an audio application in Ruby which needs low latency audio playback. So far, I'm using SDL, which is great for a prototype, but it's got nowhere near enough performance for what I need.

I've tried using the ruby-jack gem, but it doesn't seem complete enough to inject any audio into a playback port (and the documentation is wildly incomplete).

If it changes much, I'm on OS X (but I'd like something that's decently cross-platform), and I'm (currently) playing back small WAV files, but more formats would be better. I don't want especially want to call a system application to do this, either.

My application's full source is available on Github; the salient features of it are in a gist, for those who want to have a look.

1
How do you use SDL to play samples/tracks ? If there are no some redundant layers or indirections in ruby code, no performance issues has to be expected. Are you trying to run playback in a thread ? Question has to be updated with more info to get some reasonable answer. - David Unric
I'll post a link to what code I already have, but the salient points are covered in gist.github.com/Jashank/5179273 - Jashank Jeremy

1 Answers

0
votes

I'm not too certain if I have the correct answer for you, but I believe it may be worth your time to look into rbSFML. It is a binding for SFML, a multi media library, which has been growing in popularity.

Go here for rbSFML http://groogy.se/mainsite/rbsfml/

SFML main page http://www.sfml-dev.org/

Wish I had more information for you!