| View previous topic :: View next topic |
| Author |
Message |
BigBadKing

Joined: 09 Oct 2009 Posts: 86 Location: Space
|
Posted: Fri Oct 09, 2009 1:04 pm Post subject: What is the most simplest way for loading sounds? |
|
|
i design games in FreeBasic, now i want to make a game which can
play sounds, and now can i ask you that "what is the most simplest
way for playing sounds in a game". thanks for your attention. _________________ Macselent Corporation Offical Site |
|
| Back to top |
|
 |
burger2227

Joined: 21 Aug 2006 Posts: 888 Location: Pittsburgh, PA
|
Posted: Fri Oct 09, 2009 3:10 pm Post subject: |
|
|
Try QB64. It has sound functions that are simple to use.
Otherwise you may wait a long time here for an answer. Try the FB site. _________________ Please acknowledge that you have read an answer!
QB64 is a FREE QBasic compiler for 32/64 bit WIN and LINUX PC's! : http://www.qb64.net/forum/
Get my Q-Basics demonstrator here (fast download): http://dl.dropbox.com/u/8440706/Q-Basics.zip |
|
| Back to top |
|
 |
Nodtveidt

Joined: 25 Jul 2004 Posts: 830 Location: Quebradillas, PR
|
Posted: Fri Oct 09, 2009 6:57 pm Post subject: |
|
|
burger, this forum is not for promoting QB64. Keep that propaganda in the QB forum.
BigBadKing, look into libraries such as FMOD, Bass, FBsound, etc. There are plenty to choose from. _________________ NDS Uncensored
A Little de Todo |
|
| Back to top |
|
 |
BigBadKing

Joined: 09 Oct 2009 Posts: 86 Location: Space
|
Posted: Sat Oct 10, 2009 4:26 am Post subject: I found it! thanks. |
|
|
| Thanks, i found the solution. |
|
| Back to top |
|
 |
SumoAlien

Joined: 11 Oct 2009 Posts: 9
|
Posted: Sun Oct 11, 2009 1:58 pm Post subject: |
|
|
tried OpenGl? it has 3D sound, that means full control of the sound. for an example, goto your freebasic directory then to the examples and to finish to the sound direction. fire up OpenGL.bas, and use it...  |
|
| Back to top |
|
 |
chung

Joined: 20 Apr 2010 Posts: 18
|
Posted: Tue Apr 20, 2010 9:06 am Post subject: |
|
|
personnaly, i use current windows system mcisendstring api to load and play mp3 files and it works.
(no added software needed)
| Code: | #include "win/mmsystem.bi"
Sub initsounds
Dim As String soundfic
soundfic="sounds/slash.mp3"
mcisendstring("open "+chr$(34)+soundfic+chr$(34)+" shareable alias slash",0,0,0)
soundfic="sounds/impact.mp3"
mcisendstring("open "+chr$(34)+soundfic+chr$(34)+" shareable alias impact",0,0,0)
'etc...
End Sub
Sub closesounds 'on exit
mcisendstring("close slash",0,0,0)
mcisendstring("close impact",0,0,0)
End Sub
Sub soundslash
mcisendstring("play slash from 0",0,0,0)
End Sub
Sub soundimpact
mcisendstring("play impact from 0",0,0,0)
End Sub
'etc... |
|
|
| Back to top |
|
 |
|