Audio and sound

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Soldier of infortune
Posts: 29
Joined: Fri Sep 19, 2003 8:36 am

Audio and sound

Post by Soldier of infortune »

I'd like to add a background music in my game Komando,
I use Linux with Audiere (the sound engine).
The Techdomo runs perflectly under Windows with sound. So i modify this code to my game source code.
But I have got a lot of error ! :-(

Have you got a piece a code that runs under Linux ?

Thanks in advance.
DarkWhoppy
Posts: 386
Joined: Thu Sep 25, 2003 12:43 pm
Contact:

Post by DarkWhoppy »

I've been having abit of trouble with Audiere, when I use it in more than one of my 'classes' it crashes. (I use Windows) But a suggestion would be to try another sound API... FMOD and BASS are ok.

Also, did you make sure to include the right files and link the library? (audiere.lib)
Cleves
Posts: 224
Joined: Mon Sep 08, 2003 6:40 pm

Post by Cleves »

Hey all,

I had the same problem with audiere.So i decided to move to OpenAL.
It's really easy and gives you more control on your sound.
Here are some tutorials that may help you:http://www.devmaster.net/articles.php?catID=6
Soldier of infortune
Posts: 29
Joined: Fri Sep 19, 2003 8:36 am

Post by Soldier of infortune »

You are right DarkWhoppy !

I forget to link my program to audiere.a library !!

Here my game with background sound :stimpunx.fr.st

Thanks a lot !
DarkWhoppy
Posts: 386
Joined: Thu Sep 25, 2003 12:43 pm
Contact:

Post by DarkWhoppy »

Looks sweet man! Is it gonna be a 3rd Person Shooter?
Soldier of infortune
Posts: 29
Joined: Fri Sep 19, 2003 8:36 am

Post by Soldier of infortune »

Yes, I want to make this kind of game. But there are a lot thing to do !!
[dx/x]=HUNT3R
Posts: 271
Joined: Sat Aug 23, 2003 5:52 pm
Location: Hurricane Central, Florida

Post by [dx/x]=HUNT3R »

I've been using Audiere for a while and it works fine. You just gotta know how to call it correctly. You create an AudioDevicePtr and a sound object at the beginning of your code like so

Code: Select all

AudioDevicePtr audioDevice(OpenDevice());
OutputStreamPtr menu_music = 0;
And then somewhere in your code you need to load a sound in the object like this:

Code: Select all

menu_music = OpenSound(audioDevice, "supa-g1.ogg", true);
And then there's all kinds of calls you can make to a sound object but typically when you just want to play it somewhere you'll do this:

Code: Select all

menu_music->setVolume(MUSIC_VOLUME);
menu_music->setRepeat(true);
menu_music->play();
DarkWhoppy
Posts: 386
Joined: Thu Sep 25, 2003 12:43 pm
Contact:

Post by DarkWhoppy »

Audiere worked fine until I added the libraries to another class... even before I setup the device and stream it causes a heap of errors...
Post Reply