[Openal] set or enqueue buffer?

Jason Daly jdaly at ist.ucf.edu
Thu Jun 7 08:22:32 PDT 2007


uray meiviar wrote:
> what is the difference between
> void alSourcei( ALuint source, ALenum param, ALint value );
> and
> void alSourceQueueBuffers( ALuint source, ALsizei n, ALuint* buffers );
> ?
>
> yes, i know alSourceQueueBuffer is for streaming and alSourcei is for 
> static playing, but what makes it different?
> does alSourceQueueBuffer is after the buffer played, it is 
> automatically detached from source?
> does alSourcei enabled you to replay when you call alSourcePlay 
> multiple times and alSourceQueueBuffer is not?
> or just alSourceQueueBuffer is to ensure that buffer addition won't 
> interrupt the playing process?

The alSourcei method (assuming you use AL_BUFFER for param) effectively 
unqueues all buffers from the source, and queues the single buffer that 
you specify.  Other than this, it behaves exactly the same as 
alSourceQueueBuffers.  Buffers are never unqueued after playing, so you 
can always play any queued buffers repeatedly.

-- 

--"J"

"I'm a castaway stranded in a desolate land,
 I can see the footprints in the virtual sand."
	--Neil Peart

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://opensource.creative.com/pipermail/openal/attachments/20070607/8c5169a6/attachment.html


More information about the Openal mailing list