开发者

Best cross-platform audio library for synchronizing audio playback

开发者 https://www.devze.com 2022-12-18 10:41 出处:网络
I\'m writing a cross-platform program that involves scrolling a waveform along with uncompressed wav/aiff audio playback. Low latency and accuracy are pretty important. What is the best cross-platform

I'm writing a cross-platform program that involves scrolling a waveform along with uncompressed wav/aiff audio playback. Low latency and accuracy are pretty important. What is the best cross-platform audio library for audio playback when synchronizing to an external clock? By that I mean that I would like to be able to write the playback code so it sends events to a listener many times开发者_如何学Python per second that includes the "hearing frame" at the moment of the notification. That's all I need to do. No recording, no mixing, no 3d audio, nothing. Just playback with the best possible hearing frame notifications available.

Right now I am considering RTAudio and PortAudio, mostly the former since it uses ALSA. The target platforms, in order of importance, are Mac OSX 10.5/6, Ubuntu 10.11, Windows XP/7. C/C++ are both fine.

Thanks for your help!


The best performing cross platform library for this is jack. Properly configured, jack on Linux can outperform Windows asio easily (in terms of low latency processing without dropouts). But you cannot expect normal users to use jack (the demon should be started by the user before the app is started, and it can be a bit tricky to set up). If you are making an app specifically for pro-audio I would highly recommend looking in to jack.

Edit:

Portaudio is not as high-performance, but is much simpler for the user (no special configuration should be needed on their end, unlike jack). Most open source cross platform audio programs that I have used use portaudio (much moreso than openal), but unlike jack I have not used it personally. It is callback based, and looks pretty straightforward though.


OpenAL maybe an option for you.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号