View previous topic :: View next topic |
Author |
Message |
Labman
Joined: 05 Nov 2004 Posts: 51 Location: Brisbane, Australia
|
Posted: Tue Feb 02, 2010 6:10 am Post subject: Sound API of choice |
|
|
What is your sound API of choice? I'm looking into implementing sound into my game prototype engine but I'm not sure which API to look at...
Cross platform would be a big plus. Currently I'm using OpenGL and SDL, so I would like to keep my platform options open with the sound API too. |
|
Back to top |
|
 |
c0burn
Joined: 05 Nov 2004 Posts: 158 Location: Liverpool, England
|
|
Back to top |
|
 |
dreadlorde

Joined: 24 Nov 2009 Posts: 86
|
Posted: Tue Feb 02, 2010 1:29 pm Post subject: |
|
|
I'm pretty sure on Linux you will need to do some crap with ALSA and/or OSS if you want sound. I don't think you can just send sound to /dev/dsp or where ever and have it play... _________________
Ken Thompson wrote: | One of my most productive days was throwing away 1000 lines of code. |
Get off my lawn! |
|
Back to top |
|
 |
Spirit

Joined: 20 Nov 2004 Posts: 476
|
Posted: Tue Feb 02, 2010 6:38 pm Post subject: |
|
|
That's why you simply use SDL and as a side effect get nice libraries for networking, input etc which are easily ported to Windows and the Mac too. _________________ Quake Maps |
|
Back to top |
|
 |
c0burn
Joined: 05 Nov 2004 Posts: 158 Location: Liverpool, England
|
Posted: Tue Feb 02, 2010 9:03 pm Post subject: |
|
|
SDL has networking? |
|
Back to top |
|
 |
Spike
Joined: 05 Nov 2004 Posts: 944 Location: UK
|
Posted: Tue Feb 02, 2010 9:14 pm Post subject: |
|
|
the general recommendation for linux is to just use sdl for sound.
Reasoning: ALSA sucks more than the win3.1 api and has about as many bugs as there are stars in our galaxy. OSS is about as well supported as the win3.1 api, but does at least sound more like a farrari...
Really SDL is the most stress free and reliable way to get audio in linux. Be aware that it fills the output sound buffer in a separate thread, as required.
Using SDL gives you a quick and easy work around for all the bugs in the distribution's random choice of alsa version, or uses oss if the user knew how to install it and configure their system for it. It just magically works. Unlike ALSA.
I'm not personally aware of SDL having networking, but then I've never found BSD sockets to differ that much between the more important operating systems. You can generally just abstract the differences with a single header file and a few #defines. _________________ What's a signature? |
|
Back to top |
|
 |
Teiman
Joined: 03 Jun 2007 Posts: 309
|
Posted: Tue Feb 02, 2010 9:55 pm Post subject: |
|
|
c0burn wrote: | SDL has networking? |
SDL is somewhat like DirectX, has lots of "expansions".. and one is SDL_net. |
|
Back to top |
|
 |
Labman
Joined: 05 Nov 2004 Posts: 51 Location: Brisbane, Australia
|
Posted: Wed Feb 03, 2010 1:18 am Post subject: |
|
|
I'm using SDL for window management and input currently, I was looking at it for sound but was wondering about other API's like openal might be a better choice. |
|
Back to top |
|
 |
calvincolins
Joined: 28 Jun 2010 Posts: 3
|
Posted: Fri Jul 02, 2010 7:28 am Post subject: |
|
|
Hey i think SDL for window management is work fine then why you want other API?
i think your current SDL is ok. _________________ cheap holiday to spain |
|
Back to top |
|
 |
reckless
Joined: 24 Jan 2008 Posts: 390 Location: inside tha debugger
|
Posted: Fri Jul 02, 2010 12:07 pm Post subject: |
|
|
SDL_sound
bitch to compile though
but it hooks into openal ogg/vorbis etc. so plenty choices. |
|
Back to top |
|
 |
|