Distance-attenuation Extension

Version 2 (Nils Peters, 07/05/2011 12:46 am)

1 1 Nils Peters
h1. Distance-attenuation Extension
2 1 Nils Peters
3 1 Nils Peters
Review of concepts for simulating distance attenuation of sound sources.
4 1 Nils Peters
5 1 Nils Peters
h2. MIDI Manufacturers Association, Interactive Audio Special Interest Group 3D Level 1 Guideline
6 1 Nils Peters
7 1 Nils Peters
source: http://www.midi.org/techspecs/rp49public.pdf
8 1 Nils Peters
9 1 Nils Peters
10 2 Nils Peters
* Distance Ratio Parameter
11 2 Nils Peters
* Maximum Distance Parameter
12 2 Nils Peters
* Gain at Maximum Distance Parameter
13 2 Nils Peters
* Reference Distance Ratio Parameter
14 2 Nils Peters
15 2 Nils Peters
!spatial-midi.png!
16 2 Nils Peters
17 2 Nils Peters
The actual attenuation due to distance is computed as:
18 1 Nils Peters
 
19 2 Nils Peters
@attenuation@ = 20*log10(@referenceDistance@ / (@referenceDistance@ + @ROF@ (@distance@ - @referenceDistance@)))
20 2 Nils Peters
21 2 Nils Peters
@ROF@, the roll-off factor is defined as:
22 2 Nils Peters
23 2 Nils Peters
@ROF@ = (@referenceDistance@ * 10^(- @maxAttenuation@ * 0.05) - @referenceDistance@) / (@maxDistance@ - @referenceDistance@)
24 2 Nils Peters