User Tools

Site Tools


arma2:sound

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
arma2:sound [2010-09-10 06:35]
snakeman added more details.
arma2:sound [2011-06-30 14:17]
Line 1: Line 1:
-====== ArmA 2 Sound ====== 
  
-If there are 3 parameters, then from second (volume in dB) is used for maximum distance calculation,​ max. distance is emitter distance from listener where sound from this emitter is not audible. 
- 
-When in cfg are four parameters, then 4 parameter is distance in meters, and second parameter (volume in dB) is ignored - is recalculated based on max distance. 
- 
-0dB == 1000m 
- 
-is recalculated based on max distance 
- 
-What max distance is this - related to view distance? 
- 
-Sample volume is recalculated,​ volume is derived from distance ( where 0dB = 1000m ), there is no "​real"​ difference between these to entries. 
- 
-Distance == view distance. 
- 
-Some more good information - details about new class Sounds of cfgVehicles. 
- 
-  * frequency range is [0.6, inf] but usable range is somewhere about 1 that's [0.8, 1.2] 
-  * randomizer = small random number unique for each vehicle, range [0, 1] 
-  * angular velocity - but this controller is not much usable, because values are discrete, not smooth, so in frame N it should be 0 and in frame N+1 it should be 2 
-  * factor - linear interpolation between A and B based on x, value = A + (B - A) *x, trick to get peak is using min{ X factor [A, B], X factor [B, A] } 
- 
- 
-====== Example config ====== 
- 
-Here is example helicopter engine / rotor sound config. 
-<code cpp> 
- class Sounds 
- { 
- class Engine 
- { 
- sound[] = {"​pmc\vte_sounds\vehicle\CH47_engine_high_ext.wss",​ 1, 1, 800}; 
- frequency = "​rotorSpeed";​ 
- volume = "​camPos*((rotorSpeed-0.72)*4)";​ 
- }; 
-  
- class RotorLowOut 
- { 
- sound[] = {"​pmc\vte_sounds\vehicle\CH47_rotor_ext.wss",​ 3.1622777, 1, 1500}; 
- frequency = "​rotorSpeed";​ 
- volume = "​camPos*(0 max (rotorSpeed-0.1))";​ 
- cone[] = {1.8,​3.14,​2.0,​0.9};​ 
- }; 
-  
- class RotorHighOut 
- { 
- sound[] = {"​pmc\vte_sounds\vehicle\CH47_rotor_forsage_ext.wss",​ 3.1622777, 1, 1800}; 
- frequency = "​rotorSpeed";​ 
- volume = "​camPos*10*(0 max (rotorThrust-0.95))";​ 
- cone[] = {1.8,​3.14,​2.0,​0.9};​ 
- }; 
-  
- class EngineIn 
- { 
- sound[] = {"​pmc\vte_sounds\vehicle\CH47_engine_high_int.wss",​ 1.7782794, 1}; 
- frequency = "​rotorSpeed";​ 
- volume = "​(1-camPos)*((rotorSpeed-0.75)*4)";​ 
- }; 
-</​code>​ 
- 
-CfgEnvSounds example 
-<code cpp> 
-class CfgEnvSounds 
-{ 
-        class Meadows 
-        { 
-        sound[] ={"​\ca\sounds\Ambient\meadows\wind-meadow-2",​0.0316228,​1};​ 
-        volume = "​(1-forest)*(1-houses)*(1-night)*(1-sea)";​ 
-        randSamp1[] ={"​ca\sounds\Ambient\meadows\meadow_sfx_01",​0.1,"​125",​0.15,​8,​15,​20};​ 
-        randSamp2[] ={"​ca\sounds\Ambient\meadows\meadow_sfx_02",​0.1,​1,​25,​0.15,​8,​15,​20};​ 
-        randSamp3[] ={"​ca\sounds\Ambient\meadows\meadow_sfx_03",​0.1,"​125",​0.15,​15,​30,​40};​ 
-        randSamp4[] ={"​ca\sounds\Ambient\meadows\meadow_sfx_04_crickets",​0.01,​1,​25,​0.15,​15,​30,​40};​ 
-        randSamp5[] ={"​ca\sounds\Ambient\meadows\meadow_sfx_05_crickets",​0.00562341,​1,​25,​0.1,​8,​15,​20};​ 
-        randSamp6[] ={"​ca\sounds\Ambient\meadowsmeadow-sfx-06",​0.01,​1,​25,​0.1,​8,​10,​20};​ 
-        random[] ={"​randSamp1","​randSamp2","​randSamp3","​randSamp4","​randSamp5","​randSamp6"​};​ 
-        }; 
- 
-        class Forest 
-        { 
-                sound[] ={"​ca\sounds\Ambient\forestforest-day-2",​0.0398107,​1};​ 
-                volume = "​forest*(1-night)";​ 
-                randSamp11[] ={"​ca\sounds\Ambient\forestforest-sfx-9bird",​0.1,​1,​30,​0.14,​5,​8,​10};​ 
-                randSamp10[] ={"​ca\sounds\Ambient\forestforest-sfx-12datel",​0.1,​30,​0.125,​10,​20,​40};​ 
-                randSamp0[] ={"​ca\sounds\Ambient\forestforest-sfx-5bird",​0.125893,​1,​30,​0.13,​4,​8,​12};​ 
-                randSamp1[] ={"​ca\sounds\Ambient\forestforest-sfx-6bird",​0.125893,​1,​30,​0.125,​4,​8,​12};​ 
-                randSamp2[] ={"​ca\sounds\Ambient\forestforest-sfx-7bird",​0.125893,​1,​30,​0.125,​4,​8,​12};​ 
-                randSamp3[] ={"​ca\sounds\Ambient\forestforest-sfx-8bird",​0.125893,​1,​30,​0.1,​4,​8,​12};​ 
-                randSamp8[] ={"​ca\sounds\Ambient\forestforest-sfx-10bird-flapping",​0.1,​1,​30,​0.04,​10,​20,​40};​ 
-                randSamp9[] ={"​ca\sounds\Ambient\forestforest-sfx-11holub-flapping",​0.1,​1,​30,​0.04,​10,​20,​40};​ 
-                randSamp4[] ={"​ca\sounds\Ambient\forestforest-sfx-1",​0.1,​1,​30,​0.025,​4,​8,​10};​ 
-                randSamp5[] ={"​ca\sounds\Ambient\forestforest-sfx-2",​0.1,​1,​30,​0.025,​4,​8,​10};​ 
-                randSamp6[] ={"​ca\sounds\Ambient\forestforest-sfx-3",​0.1,​1,​30,​0.025,​4,​8,​10};​ 
-                randSamp7[] ={"​ca\sounds\Ambient\forestforest-sfx-4",​0.1,​1,​30,​0.025,​4,​8,​10};​ 
-                random[] ={"​randSamp11","​randSamp10","​randSamp0","​randSamp1","​randSamp2","​randSamp3","​randSamp8","​randSamp9","​randSamp4","​randSamp5","​randSamp6","​randSamp7"​};​ 
-        }; 
- 
-        class ForestNight 
-        { 
-                sound[] ={"​ca\sounds\Ambient\forestforest-night-1",​0.0562341,​1};​ 
-                volume = "​forest*night";​ 
-                randSamp1[] ={"​ca\sounds\Ambient\forestforest-night-sfx-1",​0.1,"​125",​0.15,​8,​15,​20};​ 
-                randSamp2[] ={"​ca\sounds\Ambient\forestforest-night-sfx-2",​0.1,​1,​25,​0.15,​8,​15,​20,​30};​ 
-                randSamp3[] ={"​ca\sounds\Ambient\forestforest-sfx-10bird-flapping",​0.1,"​125",​0.15,​15,​30,​40};​ 
-                randSamp4[] ={"​ca\sounds\Ambient\forestforest-sfx-11holub-flapping",​0.1,"​125",​0.15,​15,​30,​40};​ 
-                randSamp5[] ={"​ca\sounds\Ambient\forestforest-sfx-1",​0.0562341,​1,​25,​0.1,​8,​15,​20};​ 
-                randSamp6[] ={"​ca\sounds\Ambient\forestforest-sfx-2",​0.0562341,​1,​25,​0.1,​8,​10,​20};​ 
-                randSamp7[] ={"​ca\sounds\Ambient\forestforest-sfx-3",​0.0562341,​1,​25,​0.1,​8,​10,​20};​ 
-                randSamp8[] ={"​ca\sounds\Ambient\forestforest-sfx-4",​0.0562341,​1,​25,​0.1,​8,​10,​20};​ 
-                random[] ={"​randSamp1","​randSamp2","​randSamp3","​randSamp4","​randSamp5","​randSamp6","​randSamp7","​randSamp8"​};​ 
-        }; 
- 
-        class Rain 
-        { 
-                sound[] ={"​\Ca\sounds\Ambient\rain\rain_hard1",​0.177828,​1};​ 
-                volume = "​rain";​ 
-                soundNight[] ={"​\Ca\sounds\Ambient\rain\rain_hard1",​0.177828,​1};​ 
-        }; 
-</​code>​ 
- 
-Solid insideSoundCoeff'​s 
-<code cpp> 
-// UH60 
-insideSoundCoef = 0.001; 
-occludeSoundsWhenIn = 0.02; 
-obstructSoundsWhenIn = 0.02; 
-</​code>​ 
- 
-EngineLowOut {"​A10_Ext_Engine_Low",​ 45.2387, 1, 700} 
- 
-This sound you should hear last, its the rumble or 'jet wash' you get when an aircraft makes as it gets closer to your position. 
- 
-EngineHighOut {"​A10_Ext_Engine_High",​ 25.2387, 1, 1100} 
- 
-This is the '​throttle'​ sound, the sound activates when you apply acceleration as well as sounding at other (from what I can tell) drastic stick movements ? Had to define when you start to hear it but somewhere between the two others gives me the best results during a flyby. 
- 
-ForsageOut {"​A10_Ext_Engine_Idle",​ 40.2387, 1, 4000} 
- 
-This is the main engine sound, this kicks in as the the engine_start sound is fading out and plays a constant loop until you stop the engine or it gets destroyed. 
- 
-{"​V_55",​ 1.0, 0.5, 900};\\ 
-1.0 is volume at source\\ 
-0.5 is pitch 0.0 being same as orginal sample\\ 
-900 is volume over distance (how far it can be heard) 
- 
-Check out basic [[sound_config_tutorial|Sound config tutorial]]. 
arma2/sound.txt ยท Last modified: 2011-06-30 14:17 (external edit)