practical multi-processing - sound

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

practical multi-processing - sound

Adrian Sietsma
I am working on a sound library for lua (tentatively LuaSound).

The library i've ported (PortAudio) comes with a very nifty thread-safe ringbuffer, which i have built as a stand-alone userdata.

this buffer is filled by the lua app, and emptied by the sound thread (or vice-versa).

in one of my tests, i'm using


to keep a 500 ms buffer topped up.

although i've yet to do performance tests, this appears to have negligable performance impact on lua.

any better ideas ? keep it simple please - i'll have time to debate the theory when i've finished the port, (and done some paying work too)

ps i'm planning to use libsndfile for sound file support, but it's LGPL, which may limit some people's use of it (please do NOT discuss that issue here).
 anyone know of or want to build a free library ?
(i just need to get the audio samples, anyoldhow).