Table des matières
To maintain an optimal level of performance when many sounds are playing simultaneously, sounds below a certain volume level should not take up valuable processing power and memory. Instead of playing these inaudible sounds, the sound engine can queue them in the virtual voice list. Wwise continues to manage and monitor these sounds, but once inside the virtual voice list, they are no longer processed by the sound engine and won't take up one of the hardware's active voices.
When you select the virtual voices feature, sounds move back and forth between the physical and the virtual voice based on their volume levels when they are under threshold, or if their playback limit was exceeded. As the volume reaches the threshold set by the Wwise user in Project Settings, they are added to the virtual voice list and sound processing stops. As volume levels increase, as is the case when sounds move within the max distance radius, the sounds will move from the virtual voice list to the physical voice where they will be processed by the sound engine again.
Managing virtual voice behavior can be done in the advanced setting of any sound object, Actor-Mixer, or audio bus in the Advanced Settings tab of the Property Editor.
There are three options to choose from when determining the move from physical to virtual voice:
Continue to play - Continues playing the object as a physical voice even though it will no longer be heard.
Kill voice - Stops playing the object. No fade out is applied with this option.
Send to virtual voice - Sends the object to the virtual voice list.
When a sound or motion object is sent to the virtual voice list, certain parameters of the object are monitored by the sound engine, but no processing for audio or motion occurs.
When Send to Virtual Voice is set, there are three options that determine the behavior of sounds or motion objects that move from the virtual voice list back to the physical voice.
Play from beginning - Plays the object from its beginning. This option resets the object's loop count.
Play from elapsed time - Continues playing the object as if it had never stopped playing.
This option is not sample accurate, so sounds returning to the physical voice may be out of sync with other sounds playing.
Resume - Pauses the object when it moves from the physical voice to the virtual voice list and then resume playback when it moves back to the physical voice.
Each behavior has its own performance characteristics, as demonstrated in the following table:
Streamed sounds stop consuming I/O bandwidth while they are virtual. When the selected behavior is Play From Beginning or Play from Elapsed Time, the I/O buffer is flushed. This causes a delay before the sound is heard again when the voices switch from virtual to physical.
In short, taking control of instances and priorities can actually change the sound of your game. Special care and handling should be used when defining the properties at every level of both the Actor and Master-Mixer Hierarchies. Restrictively modifying these setting can prevent important sounds from being heard appropriately, in the same way that ignoring the setting can result in unwelcome behavior.
For additional information on Instance Limiting, Prioritization, and Virtual Voices: