Files
UnrealEngineUWP/Engine/Source/Developer/AssetTools
Aaron McLeran bb31416059 New feature for defining grouped max concurrency rules
Overview:
- Created a new UObject: USoundConcurrency
- Defines concurrency behaviors and allows for different USoundBase assets (e.g. SoundWave's, SoundCues) to be a part of the same concurrency group.
- This feature will allow a number of powerful techniques to limit and control the number of sound assets which can play concurrently

Details and Additional Related Features:
- USoundBase's not specifying an override or a USoundConcurrency ref will result in no concurrency limits.
- Added support to existing static gameplay functions to provide an optional argument to override the USoundConcurrency of a sound at the point of playing
- Added a few new concurrency resolution rules: Resolve based on priority and Resolve based on volume
- Volume based concurrency resolution is implemented slightly different than the others due to the fact that it's complex/expensive to compute an active sound's volume before it plays due to SoundCue graph traversal. Thus, this step is made after a sound is already made it through one update of the SoundCue graph.
- It's now possible to limit max concurrency (both in groups and per-sound-instance) to the "owner" of a sound. This way different characters/actors can use the same USoundConcurrency ref but have different max-concurrency counts. With this technique, you can, for example, limit dialogue lines per actor without needing to make a USoundConcurrency object for each actor.
- A new optional concurrency behavior was also added at a suggestion from the Epic audio team: the ability to attenuate a sound based on the instance count of a sound in its concurrency group. I.e. as more sounds play in a concurrency group, the sound instances get quieter.

Backwards Compat:
- The old way limited sounds per USoundBase instance (and not different ones). You can recover this behavior by specifying an "Override" settings structure on the USoundBase. When you do this, the feature will only limit sound concurrency per instance and not per group. All existing assets with MaxConcurrency settings will fallback to this behavior.
- The default USoundBase behavior for new USoundBase objects is the same as the old behavior - i.e. max limit of 16 and non-grouped (i.e. will be an override)

#codereview marc.audy

[CL 2706947 by Aaron McLeran in Main branch]
2015-09-25 17:58:14 -04:00
..