About playing sounds....

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
xKlibur
Posts: 5
Joined: Sat Aug 27, 2005 12:00 am
Location: Brooklyn(NYC)

About playing sounds....

Post by xKlibur »

Does irrlicht handle sounds playing in a game or do i have to use native C++ functions for that?
thanX
Rienp
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

irrlicht is a graphics library only, you'll need an audio library.
audiere is a popular choice.
xKlibur
Posts: 5
Joined: Sat Aug 27, 2005 12:00 am
Location: Brooklyn(NYC)

Post by xKlibur »

Thanx, but i can't find any tutorial on the site...I need to know how to implement the audiere to code to play a sound "sound.wav".
Rienp
cpprules
Posts: 148
Joined: Wed Jul 27, 2005 8:37 pm
Location: on the Pedastal

Post by cpprules »

I have tryed audiere and it sucks. FMod Rules!!!!!!
it is very simply to use, and has much more suported formats( like midi ),
and on varius platforms.
Praise FMOD...
CRPG, FRPG, Oblivion Fan
Hater of Counter Strike (i hate it so much damn it)
Guest

Post by Guest »

Why does "Audiere suck" exactly? for basic load and play of sound effects and music (ogg etc)??

And more to the point - FMOD is NOT FREE for commercial games - $1000 a pop IIRC??
cpprules
Posts: 148
Joined: Wed Jul 27, 2005 8:37 pm
Location: on the Pedastal

Post by cpprules »

Audiere doesn't support MIDI which is most important to me 'cause i make old console style rpg's which must have midi. FMOD has a better documentation, forums, much more platforms are supported. And i'm not planing to make a commercial game.
CRPG, FRPG, Oblivion Fan
Hater of Counter Strike (i hate it so much damn it)
MikeR
Posts: 767
Joined: Sun Dec 26, 2004 4:03 pm
Location: Northern California USA
Contact:

Post by MikeR »

They don't get any easier than Audiere.

Code: Select all

using namespace audiere;

#pragma comment(lib, "audiere.lib")

//initialize audio in main

   AudioDevicePtr audiereDevice; 
    OutputStreamPtr stream; 

    audiereDevice = OpenDevice(); 
    if (!audiereDevice) 
     return 1; 

    stream = OpenSound(audiereDevice.get(), "sound.wav", true); 
    if (!stream) 
     return 2; 

    stream->setRepeat(false); 
    stream->setVolume(0.5f); // 25% volume 
    stream->play(); 
If it exists in the real world, it can be created in 3d

Sys specs:
AMD 3700+ 64 processor
1.0 gb ram
e-Geforce 6600 graphics 256 mb onboard ram
cpprules
Posts: 148
Joined: Wed Jul 27, 2005 8:37 pm
Location: on the Pedastal

Post by cpprules »

// well...
#include <fmod.h>

int main()
{
FSOUND_Init(44100, 32, 0);
FMUSIC_MODULE* Song;
Song = FMUSIC_LoadSong("hell.mid");
FMUSIC_PlaySong(Song);
return 0;
}
CRPG, FRPG, Oblivion Fan
Hater of Counter Strike (i hate it so much damn it)
Acki
Posts: 3496
Joined: Tue Jun 29, 2004 12:04 am
Location: Nobody's Place (Venlo NL)
Contact:

Post by Acki »

Yes, Audiere is preatty helpfull for playing backgound music and menu sound, etc.
For in game sounds you should use a 3D-audio lib, like FMod or OpenAL (my prefered lib) !!!

Audiere is that simple structured, taht there is only a little text file as dokumentation includet...
while(!asleep) sheep++;
IrrExtensions:Image
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
Reiyn
Posts: 23
Joined: Sat Mar 05, 2005 7:51 pm
Location: Canada

Post by Reiyn »

Fmod is only one DLL while Audiere seems to need about 4 or so... =/
Also I can get Fmod working easily with Dev-CPP however Audiere doesn't like DEVCPP :(

I am curious though, getting FMOD to load an mp3 from a .zip is really convoluted and complicated enough I haven't figured it out or found support here on the forums for it.

... Can Audiere easily read zipped sound files? (ie: utilize the file structure of Irrlicht?) :?
Reiyn
Creating "Chimera", an Online RPG
DAoC - Guinevere - Druid rr11
WoW - Gorgonnash - Druid 55
MikeR
Posts: 767
Joined: Sun Dec 26, 2004 4:03 pm
Location: Northern California USA
Contact:

Post by MikeR »

If you can get fmod working easily, use it.

Audiere uses 1 dll. Don't know where you get 4 from, and it compiles with dev-cpp without a problem.

Personally, I will be using openal tho. It's a better and more complete library.
If it exists in the real world, it can be created in 3d

Sys specs:
AMD 3700+ 64 processor
1.0 gb ram
e-Geforce 6600 graphics 256 mb onboard ram
cpprules
Posts: 148
Joined: Wed Jul 27, 2005 8:37 pm
Location: on the Pedastal

Post by cpprules »

FMod has a better community. But I would never even think of it if Audiere supports MIDI. And not just that, When Audiere loads a Sound Sample it can't be reloaded any more, and it can't work with arrays.
CRPG, FRPG, Oblivion Fan
Hater of Counter Strike (i hate it so much damn it)
Midnight
Posts: 1772
Joined: Fri Jul 02, 2004 2:37 pm
Location: Wonderland

Post by Midnight »

Where is the legal documentation for OpenAL??

I want to use it for 3d sound eventually since it seems to be the best choice for potentially commercial games but I can't seem to find the info about the license
cpprules
Posts: 148
Joined: Wed Jul 27, 2005 8:37 pm
Location: on the Pedastal

Post by cpprules »

I've found this on wiki:

OpenAL is open source and released under the terms of the Lesser General Public Licence (LGPL) and as such is free to use and develop with.
CRPG, FRPG, Oblivion Fan
Hater of Counter Strike (i hate it so much damn it)
Post Reply