Page 1 of 1

Sound System!

Posted: 06 Jun 2004, 03:09
by Sull
http://sull.homelinux.net/Sound.cpp
http://sull.homelinux.net/Sound.h

Exemple

soundinit(); // to init the sound
soundbgstart("./Sound/BGM/1.ogg",-1); //to play an background music
soundplay("Sound/Effect/bell.wav"); // to play a normal sound
yu can play any format ogg,mp3,wav
yu dont have to worry about mixing chanelle they are automaticely mixed
yu have to get sdl at http://www.libsdl.org/index.php

thx yu!

Posted: 06 Jun 2004, 07:13
by ElvenProgrammer
No we have to say thx to you Sull! Good work I'ltry it for the Win32 client.
Now we can play bgm! I was thinking that in this way we are disabling masking sound (which uses allegro routines), but it's not a problem in my opiniion we don't need gui sound. Elsewhere if you think gui sound it's necessary we have to recompile the entire masking lib... :roll:

.

Posted: 06 Jun 2004, 07:43
by Sull
recompile masking library? yu dont have to =)

Posted: 06 Jun 2004, 08:59
by ElvenProgrammer
Why not? If we replace all the allegro's sound functions with sdl's ones in masking code I think the lib should be recompiled

.

Posted: 06 Jun 2004, 16:50
by Sull
im using a normal dialog to set the sound with 2 homemade slider we dont have to modifie masking,maybe yu will see it next week =P

Posted: 19 Jun 2004, 23:51
by Shura
i wonder if it can play midi or mod as well, since it would save much space compared to even ogg. :?

.

Posted: 20 Jun 2004, 03:39
by Sull
maybe to play a midi yu need timidity++ on linux,and there not an easy task,maybe if yu want to translate .mid in ogg fell free to pm me =)

Posted: 10 Jul 2004, 01:42
by Guest
kth5 wrote:i wonder if it can play midi or mod as well, since it would save much space compared to even ogg. :?
If you go 24kbs ogg, or even 8kbs ogg, it's very small and sounds as good as midi atleast.