Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Chapter 13 Game Audio > Game Sound System Architecture

GAME SOUND SYSTEM ARCHITECTURE

Just like a graphics subsystem, audio subsystems can have a few different implementations. DirectSound, Miles Audio, WWise, and FMod are a few examples. It’s a good idea to create an implementation-agnostic wrapper for your sound system so that you are free to choose the implementation right for your game. The audio system presented in this chapter can use DirectSound or Miles, and the only change you have to make for your high-level game code is one line of code. Figure 13.4 shows the class hierarchy for our sound system.

Figure 13.4
Sound system class hierarchy.

image

The sound system inherits from IAudio. This object is responsible for the list of sounds currently active. As you might predict, you only need one of these for your game. The Audio base class implements some implementation-generic routines, and the DirectSoundAudio class completes the implementation with DirectSound-specific calls.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial