[Openal] New member - Compiling OpenAL example on Macintosh

E. Wing ewmailing at gmail.com
Fri Mar 13 21:18:57 PDT 2009


On Fri, Mar 13, 2009 at 6:13 PM, Cara Quinn <caraquinn at caraquinn.com> wrote:

>   Eric, Wow!  Thanks for the wealth of leads / info!  :)
>   -am looking at the OpenAL example right now.
>
>   As per my note, you gave me just what I needed!  :)  I simply needed the
> proper type for 'device' so the ALCdevice* pointer was part of the missing
> link that the docs didn't mention and I couldn't seem to locate. eek!
>  -either poor docs or my poor lil blonde head!  lol!
>
>   anyway, the only issue I have now is the loading / unloading as you also
> cover in your note.
>
>   I'm actually wanting to stay cross-platform here so I'm thinking I'll use
> SDL, as the project I'm working on already has SDL support.  (I'm trying to
> use OpenAL for a 'proof-of-concept') as we're not certain if SDL will
> ultimately perform the way we'd like.
>

It is fine to use SDL and OpenAL together in a project. Just don't
initialize (or disable) the SDL audio subsystem when using OpenAL. Then
everything should pretty much work.

I like using SDL_sound because it only focuses on sound loading/decoding,
not playback, so it can integrate nicely with an SDL+OpenAL based project.


  So, just to be clear, you're saying that there is actually no current way
> with the default install of OpenAL on Mac to load / unload files using
> straight OpenAL?…
>

Correct (not counting the cheat I mention). This is analogous to OpenGL and
image files. The OpenGL spec is file format agnostic and only specifies
textures. It is up to you to figure out how to load your BMPs. JPEGs, TGAs,
PNGs, etc. and get it into an OpenGL texture. Same is true for OpenAL and
WAVs, MP3s, FLACs, etc. and getting them into an alBuffer.


  Anyway, -one more curious question…
>
>   according to the 1.1 spec, the old alutLoadWAVFile() and alutUnloadWAV()
> methods seem to be changed to loadWAVFile() and unloadWAV(), respectively.
>  If Apple really is adhering to 1.1 then why in the world aren't these two
> methods supported?…  :)  It doesn't make sense to me.
>

This one is news to me. As far as I was aware, all of alut and file format
loading was removed from the spec. Can you point to where in the spec you
see this?



>   Also, are these two methods actually still in the alut.h library, even
> though the names have been changed?…
>

So again, you shouldn't be trying to #include "alut.h" and using any alut
funcation as the original alut is dead and the only way to access it on Mac
is through the cheat I mentioned. If you use the cheat, you must use all the
names/signatures of what Apple used which was different from what
Creative/Windows used, and different from what Loki/Linux used. So whatever
document you found, it is probably wrong for you as it probably was not
about the Apple version. But this cheat shouldn't be done for production
code as Apple reserves the right to remove the symbols completely at any
time.

If you use the new 3rd party reinvented alut, you need to rename everything
to avoid symbol clashes.

This is probably more confusing than it should be. If you are confused, my
suggestion is pretend you never heard of alut and that it doesn't exist.


-Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://opensource.creative.com/pipermail/openal/attachments/20090313/3637c807/attachment.html


More information about the Openal mailing list