★ TouchArcade needs your help. Click here to support us on Patreon.

cocos2d audio

05-20-2009, 11:48 AM
#1
Joined: May 2009
Posts: 2
cocos2d audio

Hi,

Is anyone using the audio functionality that comes with cocos2d? I noticed that it is experimental; but, I thought it might be working well enough to be used.

Thanks,
05-21-2009, 03:19 PM
#2
Joined: May 2009
Location: Charlotte, NC
Posts: 22
Quote:
Originally Posted by touchpod View Post
Hi,

Is anyone using the audio functionality that comes with cocos2d? I noticed that it is experimental; but, I thought it might be working well enough to be used.

Thanks,
I'm using the Audio Engine in Road Rage Ahead, and it's sufficient. My only problem was that it tied a single sound file to one buffer, so you could only play one instance of the sound at a time, which required a bit of modification in the engine code.

Bottom line, it has been very stable for me, and I think it's fine.

There is a new engine that was posted, CocosDenshion, which has a lot more features that I want, and removes some of the things that I don't need for my game, like positional audio. CocosDenshion seems to simplify it to panning L/R rather than coordinate based audio. I have not messed with the new engine, but others have reported good results.

Road Rage Ahead, Tailgate Games, Tic Tac Ultimate - www.ryaneade.com

05-21-2009, 05:06 PM
#3
Good tip on CocosDenshion. I've been looking for a good sound engine for my game, which needs multiple sound instances. I will give it a try after work.

Development blog for Wormies, my first iPhone game:
http://wormiesiphone.blogspot.com/
05-21-2009, 08:13 PM
#4
Joined: May 2009
Posts: 2
Excellent tip, Thanks for the help !!
05-22-2009, 01:21 AM
#5
I'm the developer of CocosDenshion. Please be aware that it has a slightly different license to cocos2d in that people/entities that are rich (revenue > $250KUS) must donate to the cocos2d project and if you use CocosDenshion you must acknowledge cocos2d in your app.

CocosDenshion is based on Apple's oalTouch example, as was the experimental sound engine in cocos2d. As has been mentioned, the main differences are that Denshion just uses a simple left/right panning model and Denshion allows multiple playback instances of the same sound. Denshion also comes with a simple drum pad demo similar to DigiDrummer. Denshion currently only supports little endian PCM files e.g wave files.
05-23-2009, 12:07 PM
#6
Joined: Feb 2009
Location: San Jose, CA
Posts: 546
Quote:
Originally Posted by Steve Oldmeadow View Post
I'm the developer of CocosDenshion. Please be aware that it has a slightly different license to cocos2d in that people/entities that are rich (revenue > $250KUS) must donate to the cocos2d project and if you use CocosDenshion you must acknowledge cocos2d in your app.

CocosDenshion is based on Apple's oalTouch example, as was the experimental sound engine in cocos2d. As has been mentioned, the main differences are that Denshion just uses a simple left/right panning model and Denshion allows multiple playback instances of the same sound. Denshion also comes with a simple drum pad demo similar to DigiDrummer. Denshion currently only supports little endian PCM files e.g wave files.
Neat, the 'single sound instance' was my biggest gripe, I'll have to try this.
06-02-2009, 09:05 PM
#7
CocosDenshion has now had some major upgrades including support for playing compressed IMA4 files, audio session management, compressed background music support using AVAudioPlayer and a Simple Audio Engine interface that is easy to use for people with simple requirements. CocosDenshion is now included in the cocos2d svn repository and will be included with the upcoming 0.8 release of cocos2d.