[Openal-devel] last call: ALC_EXT_disconnect

E. Wing ewmailing at gmail.com
Wed Aug 19 06:19:05 PDT 2009


On 8/18/09, Ryan C. Gordon <icculus at icculus.org> wrote:
>
> I never officially published this extension, so this is a last call for
> comments on it before I do so.
>
>    http://icculus.org/alextreg/wiki/ALC_EXT_disconnect
>

To be pedantic, I am concerned there is a potential
contradiction/ambiguity between the "What happens to queued buffers
when a device is disconnected?" and "What should the AL do in the case
of the default device".

The first line of the first question is: "all playing sources will be
stopped on disconnected". If this is to be interpreted strictly, then
that may contradict the possibility or usefulness of the following
question which allows the implementation to switch devices
transparently where I would expect the playing sources to continue
playing.



I also wanted to put this idea out there. What do people think of
having a callback function you can define (via function pointers) to
handle device changes? It seems that constantly polling for a device
change is awkward at best. I know OpenAL doesn't have any event
callbacks, but maybe looking forward to future revisions, maybe this
is desirable.

Trying to pull an example of an API that has both polling and event
driven aspects off the top of my head, I think of Zeroconf. Apple's
DNS Service Discovery API fits with the traditional BSD sockets model
and works with polling oriented select based code. But they have a
callback system to make it easy to handle certain events. I was under
the impression that Avahi's implementation does the same.

Thanks,
Eric


More information about the Openal-devel mailing list