Archived

This topic is now archived and is closed to further replies.

Necr0Potenc3

OpenAL and a spectrum analyzer

Recommended Posts

I'm quite familiar with OpenGL and I'm trying to do a spectrum analyzer like NeHe's dancing quad. After some searching I came across OpenAL which is a *huge* help compared to the waveOut method I was using. I just don't know how to use OpenAL to see which position in the sound data array is being played at the moment, so I can get that position and make the spectrum analysis of it. I could do it by calling a PlayWave type of function and starting a thread that would keep track of it, but in case the thread or the sound function fall out of syncrony (ie: high cpu usage) that wouldn't work. So that's why I need to find a way to get get the bytes that are currently in the sound card's buffer. ideas anyone? ps: no DirectSound -gR [edited by - Necr0Potenc3 on April 22, 2004 4:51:20 PM] [edited by - Necr0Potenc3 on April 22, 2004 5:42:25 PM]

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
With DirectSound you have total control over the sound buffers and the data in them...

Share this post


Link to post
Share on other sites
I recommend fmod. It's really great, and if a specturm analyzer is what you want, then it's built in.

Edit: fixed link

[edited by - fredizzimo on April 23, 2004 5:40:42 PM]

Share this post


Link to post
Share on other sites