I am currently making an OpenAL + OggVorbis streaming sound and am having some problems with the buffer size.
I made a DirectSound + OggVorbis streaming sound before and buffer size never become a problem but it does in OpenAL. If I put less than 128kb, and once there is just a little disk activity, the streaming would stop. It seems OpenAL would unqueue the buffers when no sound is played. So I have to make the buffer size big enough that things such as disk activities would not cause the streaming to stop.
However, how big is big? On my computer, it might be 128kb, but on other's computer, that might be some other number. If I allocate some big number, say, 1MB, I think it's way too big for a buffer size. Even 128kb I think is big enough already.
Or maybe you have other solutions? Currently, this is how I do the streaming:
On Play:
stream both buffers
queue buffers and attach to source
play source
On Update:
check if there is any processed buffers
for each processed buffer
unqueue
stream buffer
re-queue
next buffer
and basically that's how it's done.
StreamingSound ss1;
ss1.load( "c:\\song.ogg" );
ss1.play();
// main loop
...
ss1.update();
...