Lesson 7

Table of Contents

Memory Pools

Memory pools keep track of all runtime information provided by each SoundBank, but also handle various runtime treatments of audio like decompression buffers and Effect processing. To handle all sounds loaded into memory, the following pools are used:

  • Default Memory Pool: Contains all the properties of audio objects and Events in your Wwise project. This includes information about each and every registered game-object, like game sync values, positions, orientation, and so on.

    This pool is directly influenced by how many Events and audio objects have been loaded. As such, you can reduce the Default Memory pool by splitting SoundBanks into smaller ones or by reducing the hierarchical complexity.

  • Lower Engine Memory Pool: This pool is dedicated to the playback of sounds and is directly influenced by the number of active voices playing at once. It’s the main processing pipeline, where every playing sound is being decompressed, format-conversed, Effect-processed, and mixed, as needed. This memory pool is also the center of management for the Virtual Voice system, which you can read more about in Lesson 3.

    A well-designed virtual voice system can help reduce the amount of concurrent voices, and therefore allows you to reduce the Lower Engine Pool size. Notice that some Effects also require more memory than others, such as reverbs like the Wwise RoomVerb, which is designed to repeat a signal and uses this pool to store it temporarily.

[Tip]

You’ve already learned how to apply and optimize effects, change Conversion Settings, and Set Virtual Voice Behaviors, but try not to degrade your audio too much, as a few saved megabytes in the Lower Engine Pool might be less important than having a nice sounding game. Instead, focus on adjusting your Virtual Voice Behaviors and making sure no inaudible sounds are active.

Let’s demonstrate the use of memory pools using the Evil Heads in the Cave.

When an Evil Head is spawned, the Enemy_EvilHead_Hover_Play Event and all corresponding audio sources are retrieved from the SoundBank and registered in the Default Memory Pool. As the Evil Head approaches the Adventurer, the position of the game object is constantly updated, and its attenuation is recomputed to set the volume. As the Evil Head charges towards the Adventurer, the RoomVerb is applied to the audio sources of the EvilHead_Attack_Charge Event, and the reverb tails and reflections are temporarily saved in the Lower Engine Pool.

As such, the memory pools keep order and remember how everything is related, whereas all calculations are handled by the processor.


Was this page helpful?