Lesson 9

Table of Contents

The AkInitializer

While memory will be allocated whenever you load the contents of a SoundBank, you also need to allocate memory for initialization and management of assets, reserved as memory pools. Each type of memory pool has its own purpose and is assigned in an AkInitializer component. This component is usually located on a WwiseGlobal game object (unless it is renamed, like in the Wwise Adventure Game), which is automatically added to a new scene, by default. The AkInitalizer, along with the AkTerminator located on the same game object, is vital to starting the Wwise Sound Engine, but no more than one of each can exist.


The AkTerminator will take care of terminating the Sound Engine when you exit the game.

In the following steps, you will ensure the AkInitializer is being created in every Scene and examine some of its key properties.

  1. In the Unity menu, go to Edit and select Wwise Settings…

  2. Under Asset Management, make sure that Create WwiseGlobal GameObject is selected.

  3. Click OK.

  4. In the Hierarchy, select the WwiseGlobal game object.

You will now see two components in the Inspector: the AkInitializer and AkTerminator scripts. Within the AkInitializer toggle group you will find a property, among others, for each memory pool.


The Screenshot above depicts the Wwise 2017.2 Wwise Unity Integration. If you are using Wwise 2018.1 or above, the AkInitializer may look different.

The memory pool property values can vary considerably by type and scale of the game you are making, but typically you will only have to adjust the following memory pools.

  • Default Memory Pool contains all the properties and structures of objects in a executed scene, like registered game objects, game sync values, positions, and so on.

  • Lower Engine Memory Pool is used to play the sounds you have posted. It's the main processing pipeline, where every sound is being decompressed, Effect processed, and so on.

Imagine that you are making a game about being a detective. The game might feature a vast amount of dialogues (resulting in large SoundBanks), but you have a very small number of concurrent voices (rarely more than 4-5 sounds). With such a game, the Default Memory Pool might be larger due to the larger structure of assets, but the Lower Engine Memory Pool might be smaller as there is less to process at the same time.

In the Wwise Adventure Game, the Lower Engine Memory Pool is much larger than the Default Memory Pool. For example, when visiting the Woodlands and facing three Evil Spit Plants in combat, you would have a Number of Voices (Total) of approximately 40.

The memory pool sizes may change during the production process and are typically only finalized towards the end of the production. However, the default values provided in the Wwise Unity Integration are sufficient to get you started.