Background music and Sound FX on the Mac

Member
Posts: 96
Joined: 2011.07
Post: #1
What is a good way to play background music in a game on the Mac? I need start, stop, volume control and maybe panning.

I know that AVAudioPlayer is available on Lion, but for earlier versions (10.5 and after), I'm looking at Audio Queue Services. Is this the right way to go?

Meanwhile, I'm using OpenAL for sound effects. Are there any possible conflicts with these two?

Thanks.

respect,
pk

iFrog is coming.
Quote this message in a reply
Moderator
Posts: 1,560
Joined: 2003.10
Post: #2
Any reason not to use OpenAL for both? Since you're already using it for sound effects, it seems to me like it'd be the logical choice.
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #3
The thing is I haven't done OpenAL Buffer Queuing before and I'm pressed for time. But now that you mentioned it I might actually go for that. Thanks.

respect,
pk

iFrog is coming.
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #4
Give cocodenshion a try. Took me about 1 minute to set it up, and 1 minute to data drive all my audio
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #5
Does it do low latency sound effects also?

respect,
pk

iFrog is coming.
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #6
(Sep 6, 2011 01:11 PM)ipeku Wrote:  Does it do low latency sound effects also?

yes (though I personally have not tried it for that)
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #7
sounds good. I researched a little and it's supposedly built right on top of OpenAL. Still, I wasn't sure where to get the official package. Is there a central place to get it or a forum of people using it (if I run into trouble)?

thanks!

respect,
pk

iFrog is coming.
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #8
grab cocos2d. it comes with it
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #9
I'll check it out. Thanks!

respect,
pk

iFrog is coming.
Quote this message in a reply
Member
Posts: 96
Joined: 2011.07
Post: #10
I finally went for OpenAL both soundFX and music. It took me 6 hours to get the streaming going and I'm glad I did that. It's pretty simple in the end.

respect,
pk

iFrog is coming.
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  LoFi/8-bit Sound and Music metacollin 11 6,864 May 20, 2009 10:52 AM
Last Post: Gamecues
  Using SDL_mixer to play ogg sound (not music) effects kordova 3 6,260 Sep 1, 2006 12:29 PM
Last Post: kordova