Audio constants

From ENIGMA

Jump to: navigation, search

These are the new audio constants for the new audio system.

Constant Description
audio_old_system the legacy sound system is in use
audio_new_system the new sound system is in use

These constants are for dealing with audio fall off calculation, the formulas are as follows.

Constant Description
audio_falloff_exponent_distance gain = (listener_distance / reference_distance) ^ (-falloff_factor)
audio_falloff_exponent_distance_clamped distance = clamp(listener_distance, reference_distance, maximum_distance)

gain = (distance / reference_distance) ^ (-falloff_factor)

audio_falloff_inverse_distance gain = reference_distance / (reference_distance + falloff_factor * (listener_distance – reference_distance))
audio_falloff_inverse_distance_clamped distance = clamp(listener_distance, reference_distance, maximum_distance)

gain = reference_distance / (reference_distance + falloff_factor * (distance – reference_distance))

audio_falloff_linear_distance distance = min(distance, maximum_distance)

gain = (1 – falloff_factor * (distance – reference_distance) / (maximum_distance – reference_distance))

audio_falloff_linear_distance_clamped distance = clamp(listener_distance, reference_distance, maximum_distance)

gain = (1 – falloff_factor * (distance – reference_distance) / (maximum_distance – reference_distance))

audio_falloff_none gain = 1

These are legacy constants for use with DirectSound effects, they are deprecated and are only available for compatibility.

Constant Description
se_none No sound effect.
se_chorus Chorus sound effect.
se_echo Echo sound effect.
se_flanger Flanger sound effect.
se_gargle Gargle sound effect.
se_reverb Reverb sound effect.
se_compressor Compressor sound effect.
se_equalizer Equalizer sound effect.
Personal tools
Namespaces
Variants
Actions
Navigation
ENIGMA
Other
Toolbox