Skip to main content
gamedev.net
🔒 Locked

OpenAL Tutorials

Started by Prozak May 23, 2003 at 9:56 AM 18 replies 2.4k views
WhtRbt
WhtRbt
I was looking around for this a while ago and I couldn''t find any tutorials at all. I found a library called FMOD (fmod.org) which is just as portable as OpenAL could be. I also has 3D sound and lots of other things. I belive that it is also used in commercial projects.
FMOD does support mp3 as well as many other formats.

- Go not to the elves for counsel, for they will say both yes and no.
- Go not to the elves for counsel, for they will say both yes and no.
jon723
jon723
The OpenAL API has some pretty good documentation , why don''t you use that??
www.lefthandinteractive.net
Leyder Dylan
Leyder Dylan
Take a look on my website, I''ve a little example who uses FMOD 3.62 for playing sound.

It can read MP3 and WAV files and more ...

========================
Leyder Dylan (dylan.leyder@slug-production.be.tf
http://www.slug-production.be.tf/
========================Leyder Dylan (dylan.leyder@slug-production.be.tf http://users.skynet.be/fa550206/Slug-Production/Index.htm/
stefu
stefu
I think OpenAL SDK can be found from creative developerssite and there are samples and docs iirc.
themattgreen
themattgreen
No point in me posting this, but I just want to say fmod is great and incredibly easy to use. Why does anybody bother with directaudio when we have fmod available? The same goes for directdraw when allegro is available. Come to think of it, allegro audio is easier to use than fmod. I wonder if it''s possible to use allegro audio functions with opengl...
stefu
stefu
quote:
Original post by themattgreen
No point in me posting this, but I just want to say fmod is great and incredibly easy to use. Why does anybody bother with directaudio when we have fmod available? The same goes for directdraw when allegro is available. Come to think of it, allegro audio is easier to use than fmod. I wonder if it''s possible to use allegro audio functions with opengl...


I don''t know if I did something wrong with FMOD, but I have awful latency (about one second) in Linux. And that''s without sound server. But with the same code it is ok in Windows.
stefu
stefu
And one thing. Often (atleast in my case) you write own audio classes/functions to fit your engine resource handling, so you still have some kind of audio wrapper. So it''s no big difference using FMOD or OpenAL (very easy to use).
chab
chab
Does anyone know if creative is still working on OpenAL?
stefu
stefu
quote:
Original post by chab
Does anyone know if creative is still working on OpenAL?


Well, I thin OpenAL is somewhat ready and there''s no big revolution in sound system comin so no need to develop it imo.
But I think creative has EAX extensions in OpenAL and believe that they support some special features in them.
I don''t know, this is just what I think
chab
chab
Ok, thanks for your post.

I know there is no big revolution coming out but when I first take a look to OpenAL, I had the bad feeling that its design was too much close to DirectSound.

I think the reason is that audio hardware vendors don''t develop specific driver for it and then, the Windows version of OpenAL rely a lot on DirectSound.

The second reason I asked, is that environmental audio within OpenAL is only supported throught EAX. I''m glad that Creative has done some work for it, but as for OpenGL, I don''t really enjoy extensions especially brand specific ones.

I worked on a sound system for a game studio and I spend some time working on environmental audio with EAX 2.0 and A3D. At that time, I prefered A3D''s design, but both of them didn''t convinced me.

So, I''m a bit sad about OpenAL because I like its interface design but don''t trust Creative to make it better by embedding directly environmental audio in it rather throught extension.

Have a nice week-end!
Mulligan
Mulligan
I really have nothing to add to this topic except praise for FMOD, i love it to death because I hate implementing sound for some reason and FMOD made it very easy for me.
NaliXL
NaliXL
Well, FMod might be good (although with my own PC, it gave a crackling sound when playing an MP3 via one of the FMOD demo-programs), but you know, it itn''t free if you''re thinking about useing your program commercially.

I found out that OpenAL actually is alive these days, some docs and the downloads can be found at http://developer.creative.com/landing.asp?cat=1⊂=31⊤=38

Good luck!
Newbie programmers think programming is hard.Amature programmers think programming is easy.Professional programmers know programming is hard.
chab
chab
Thanks NaliXL!

I browse for the link in your post and found the OpenAL SDK... It is the same since its first release. That''s a good news for sound system developers, the API has a stable design, so they don''t need to rewrite their library on each project.

But I''m wondering why we, as audio software and hardware developers, don''t learn from what happened in the graphic hardware development. DSPs on audio hardware are quite powerful nowdays but we can''t program them directly. It reminds me what happened for the first generation of T&L graphic card.

I remember there was a trick to enable a powerful ParamEQ on some Sound Blaster. I''d never use it because there was a lack of documentation about it and it seemed too much tricky for me. That''s quite a pity, especially because the functionality was there but maybe too advanced to be considered in games.

Since that time, for each new version announcement of EAX, I hope Creative make something very flexible and useful for audio developers. But each time, I have the bad feeling that those announcements are only motivated by the marketing.

As long as Creative leads the market as an audio hardware vendor for games, I will keep on hoping
KingJeihova9
KingJeihova9
I''ve recently downloaded the OpenAL Software Development Kit. OpenAL is much better than DirectX Audio(DirectSound). I''m following a game programming book entitled, "OpenGL Game Programming". The authors of that book made an idiotic move by using DirectInput for keyboard/mouse support and using DirectSound for audio support. Anything DirectX-related is unreasonably complicating and isn''t recommended for beginners and/or intermediate game programmers. If you want 3D Sound then use OpenAL. If you just want to load/play music(.ogg, .mid) then use SDL_mixer. I like mp3s but I use an .ogg/.mp3 converter and converted my mp3s to .ogg so now I could use some good songs with SDL_mixer.

If you didn''t bother to read my post I''ll just summarize it. All I did was recommended some things. Here there are:

2D Graphics: SDL
3D Graphics: OpenGL
2D Sound: SDL_mixer
3D Sound: OpenAL
Music: SDL_mixer

-Against-
2D Graphics: DirectDraw
3D Graphics: DirectX Graphics(Direct3D)
2D Sound: DirectSound
3D Sound: DirectSound
Music: DirectX Audio(DirectSound)

(My Wisdom) + (My Courage) + (My Will) > God''s Power - (ytilaerlariv) = [My] laissez faire [for] Liberatis
(My Wisdom) + (My Courage) + (My Will) > God's Power - (ytilaerlariv) = [My] laissez faire [for] Liberatis
Trienco
Trienco
what could be easier than openal? it has the same structure as opengl and i was surprised that i just had to use the default device, set the positions and get 5.1 sound without really doing anything. ogg support is still beta and for me only works in software (surprise, waiting for new drivers from nvidia). if you can get perfect 3d sound without knowing anything about openal and just having a quick look at the docs from time to time i wonder how much easier it would have to be for some?

"I wonder if it''s possible to use allegro audio functions with opengl..."

now either you lost all credibility or allegro is a horrible mess (why else should its audio part have anything to do with opengl?).. or of course it was a typo and leads to the question "why mix openal and allegro audio?"
f@dzhttp://festini.device-zero.de
frostburn
frostburn
OpenAL is LGPL and has been used in a lot of commercial products (Unreal engine, Torque, Postal2 to mention a few).
AFIK it''s legal to use LGPL''ed products in commercial products as long as you provide the source code to the LGPL''ed product (In this case the OpenAL library). If you make any changes to the library specific to your engine, the provided source code must include these changes. You don''t have to provide the source code for the entire game.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.