O'Reilly logo

Building Android Games with Cocos2d-x by Raydelto Hernandez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. Audio

The Cocos2d-x framework comes with an audio engine called CocosDenshion, which has been inherited from Cocos2d for iPhone. This engine encapsulates all the complexity of playing sound effects and background music. Now, Cocos2d-x has another audio engine that was built from scratch with the aim of providing more flexibility than the CocosDenshion library. Be aware that there is no plan to eliminate the CocosDenshion audio engine from the Cocos2d-x framework, it is now common in Cocos2d-x to have redundant components so that programmers can pick whatever fits their needs better.

The following topics will be covered within this chapter:

  • Playing background music and sound effects
  • Modifying the audio properties
  • Handling audio when leaving ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required