[Openal] Max number of sources (and legit id values) for each OpenAL implementation

Daniel PEACOCK dpeacock at creativelabs.com
Tue Jul 21 02:19:52 PDT 2009





Hi,

Those numbers are correct for Generic Hardware and Generic Software.

Creative ships various other OpenAL devices that support between 60 and 128
sources.

We used to ship an OpenAL implementation that would return 0 for a valid
Source ID.  However we found some problems in the field with games that
were doing things like ...

if (sourceID)
      // found valid source do something with it

instead of ...

if (alIsSource(sourceID))
      // found valid source do something with it

So we changed our implementations to stop returning an id of 0.  However,
as you say, the spec. does not disallow Source IDs of 0 - so code should
always use alIsSource() to validate a Source ID.

Dan
Creative Labs (UK) Ltd.

Notice
The information in this message is confidential and may be legally
privileged.  It is intended solely for the addressee.  Access to this
message by anyone else is unauthorized.  If you are not the intended
recipient,  any disclosure,  copying or distribution of the message,  or
any action taken by you in reliance on it,  is prohibited and may be
unlawful.  If you have received this message in error,  please delete it
and contact the sender immediately.  Thank you.

Creative Labs UK Ltd company number 2658256 registered in England and Wales
at Belmont Road, Belmont Place, Maidenhead, Berkshire, SL6 6TB



                                                                           
             "E. Wing"                                                     
             <ewmailing at gmail.                                             
             com>                                                       To 
             Sent by:                  OpenAL                              
             openal-bounces at op         <openal at opensource.creative.com>    
             ensource.creative                                          cc 
             .com                                                          
                                                                   Subject 
                                       [Openal] Max number of sources (and 
             07/21/2009 09:35          legit id values) for each           
             AM                        OpenAL implementation               
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           




Hi, I am writing some stuff about OpenAL and I would like to get my
facts straight. Can people verify my information about the maximum
number of sources?

Creative Labs:
I recall seeing this in an old mailing list thread.
Generic Software: 256
Generic Hardware: 16-64


OpenAL Soft:
>From the source code, I do see a hard coded value of 256, but there is
other conditional stuff in there so I'm thinking there might be other
potential values?


Mac OS X and iPhone OS:
>From the source code, it looks like the max you can request at a time
(to alGenSources) is 256. However, there doesn't seem to be anything
stopping you from making multiple calls to alGenSources of 256
sources. Probably not the intended behavior, but interesting.

Experimenting on the iPhone, the code seems to be the same here
because multiple calls of 256, give me unique source ids. (I haven't
been able to find the iPhone OpenAL source code.)


Are there any other implementations I'm forgetting?


Also, on this topic, do any implementations actually return 0 as a
valid id? I know the 1.1 spec doesn't reserve any value, but this has
always been a gotcha for me because in OpenGL, 0 is reserved.

Thanks,
Eric
_______________________________________________
Openal mailing list
Openal at opensource.creative.com
http://opensource.creative.com/mailman/listinfo/openal

ForwardSourceID:NT0006DFF6



More information about the Openal mailing list