Sound Attenuation

Sound Attenuation is essentially the ability of a sound to lower in volume as the player moves away from it. It works using two radii: MinRadius and MaxRadius. As you move from the sound's origin through the MinRadius, volume of the sound is at 100%. As you pass between the MinRadius and the MaxRadius, the volume linearly fades between 100% and silence. The rate at which this fade occurs is based on the DistanceModel property and the Distance Algorithm setting, which provides several types of falloff curves to control the volume in-between the radii. Once you pass outside the MaxRadius, you are outside the limit of the sound and hear only silence.

While the Distance Algorithm can be used to define the falloff, Attenuation Shapes can be used to specify the shape of the Attenuation Volume itself. Sphere, Capsule, Box, or Cone can be used as the Attenuation Shape based on your audio needs and how you want to confine the way the audio is presented.

Distance Algorithm

Here is a list and description of the available Distance Model Attenuation curves.

In all of the following graphs, The Y axis is volume, the X axis is distance. MinRadius is at the origin of the X axis, and MaxRadius is located at x at the right edge of the X axis.

Attenuation Linear

This attenuation model is a 1/1 reduction in volume over distance. Here is the graph:

Attenuation_Linear.JPG

Use case: Good for general looping ambience and low-detail background sounds that do not need tight 3d falloff settings. Also good for crossfading large radius ambient sounds.

Attenuation Logarithmic

This attenuation model is a logarithmic reduction in volume over distance. Here is the graph:

Attenuation_Logarithmic.JPG

Use case: Good for sounds that need more exact 3d positionalization. Also good for making sounds 'pop' at a close distance; good for incoming missiles and projectiles as well.

Attenuation LogReverse

This attenuation model is a reverse logarithmic reduction in volume over distance. Here is the graph:

Attenuation_LogReverse.JPG

Use case: Useful as a layer in weapons or other sounds that need to be loud up to their MaxRadius.

Attenuation Inverse

This attenuation model is an extremely steep falloff curve, using the equation: ( UsedMaxRadius / UsedMinRadius ) * ( 0.02 / ( Distance / UsedMaxRadius ) );

Attenuation_Inverse.JPG

Use case: Good for 3d sounds that are pinpoint loud by the MinRadius but need to be present from a distance.

Attenuation NaturalSound

The NaturalSound attenuation model is a more 'realistic' falloff model that tries to take into account how sounds are heard in an environment.

Attenuation_NaturalSound.JPG

Use case: Good for fires or other point-interest or high frequency content that the logarithmic attenuation does not feel 'right' for a sound's falloff.

Example of several Min/Max settings for Attenuation Logarithmic

Here is an example of how the MinDistance/MaxDistance Ratio changes the graph for ATTENUATION_Logarithmic:

Min 0/Max 1000:

Attenuation_Logarithmic_0_100.JPG

Min 100/Max 1000:

Attenuation_Logarithmic_100_1000.JPG

Min 500/Max 1000:

Attenuation_Logarithmic_500_1000.JPG

Min 900/Max 1000:

Attenuation_Logarithmic_900_1000.JPG

Attenuation Shapes

Examples of the Attenuation Shapes available can be found below along with sample use cases.

Attenuation Sphere

Attenuation Sphere

Use case: The default volume and is good for most usage scenarios, like ambient outside sounds (fires, birds, streams, etc.)

Attenuation Capsule

Attenuation Capsule

Use case: This could be used for hallways or other narrow passages. Could also be used to simulate riding in a train car.

Attenuation Box

Attenuation Box

Use case: Good for containing a sound within a normal squared room (dropping the box down in the image above would encapsulate the square room).

Attenuation Cone

Attnenuation Cone

Use case: Good for projecting sound at a player as the sound is at its max when inside the cone in front of the origin, directly behind the origin results in silence (the example above could represent a security camera which tracks the player).