Difference between revisions of "Documentation/Engine/Sound/TruckEngine"
(→Event "turbo") |
m |
||
(9 intermediate revisions by one other user not shown) | |||
Line 14: | Line 14: | ||
Event "engine" plays sound of the engine.<br> | Event "engine" plays sound of the engine.<br> | ||
− | It | + | It has to be 3D event. The event should be routed to the "truck_engine" audio bus.<br> |
The event must be looped and its living cycle is controlled by "play" parameter (see bellow).<br> | The event must be looped and its living cycle is controlled by "play" parameter (see bellow).<br> | ||
<br> | <br> | ||
Line 26: | Line 26: | ||
Event "exhaust" plays sound of the exhaust.<br> | Event "exhaust" plays sound of the exhaust.<br> | ||
− | It | + | It has to be 3D event. The event should be routed to the "truck_exhaust" audio bus.<br> |
The event must be looped and its living cycle is controlled by "play" parameter.<br> | The event must be looped and its living cycle is controlled by "play" parameter.<br> | ||
<br> | <br> | ||
Line 33: | Line 33: | ||
* exhaust/play | * exhaust/play | ||
* exhaust/rpm | * exhaust/rpm | ||
− | |||
The purpose of the parameters is the same as for the "engine" event (see Event "engine"). | The purpose of the parameters is the same as for the "engine" event (see Event "engine"). | ||
Line 39: | Line 38: | ||
Event "turbo" plays sound of the turbo.<br> | Event "turbo" plays sound of the turbo.<br> | ||
− | It | + | It has to be 3D event. The event should be routed to the "truck_turbo" audio bus.<br> |
The event must be looped and its living cycle is controlled by "play" parameter.<br> | The event must be looped and its living cycle is controlled by "play" parameter.<br> | ||
<br> | <br> | ||
These event parameters must exist: | These event parameters must exist: | ||
* engine/turbo<br>the value is in the range <0 - 1> and represents the action of the turbo system | * engine/turbo<br>the value is in the range <0 - 1> and represents the action of the turbo system | ||
− | |||
=== Event "start_bad" === | === Event "start_bad" === | ||
Event "start_bad" plays sound of unsuccessful starting of the engine.<br> | Event "start_bad" plays sound of unsuccessful starting of the engine.<br> | ||
− | It | + | It has to be 3D event. The event should be routed to the "truck_engine" audio bus.<br> |
The event is one-shot sound (without loop).<br> | The event is one-shot sound (without loop).<br> | ||
There are no other parameters for the event.<br> | There are no other parameters for the event.<br> | ||
Line 55: | Line 53: | ||
== Engine Sound Configuration == | == Engine Sound Configuration == | ||
− | The sound | + | The sound configuration of the engine sounds is stored in the "accessory_engine_data" data.<br> |
− | There is | + | There is array "sounds" which contents specification for the mandatory events of the engine.<br> |
That means that each type of the engine can have assigned its own sound bank.<br> | That means that each type of the engine can have assigned its own sound bank.<br> | ||
<br> | <br> | ||
Example:<br> | Example:<br> | ||
There are configuration files of engines for the "Peterbilt 579" at the folder "\def\vehicle\truck\peterbilt.579\engine".<br> | There are configuration files of engines for the "Peterbilt 579" at the folder "\def\vehicle\truck\peterbilt.579\engine".<br> | ||
+ | Each engine include ''@include "sound.sui" '' file which contents indirect definition of the events: | ||
+ | <pre> | ||
+ | sounds: 4 | ||
+ | sounds[]: "engine|/def/vehicle/truck/peterbilt.579/engine/sound_engine.soundref" | ||
+ | sounds[]: "exhaust|/def/vehicle/truck/peterbilt.579/engine/sound_exhaust.soundref" | ||
+ | sounds[]: "start_bad|/def/vehicle/truck/peterbilt.579/engine/sound_start_bad.soundref" | ||
+ | sounds[]: "turbo|/def/vehicle/truck/peterbilt.579/engine/sound_turbo.soundref" | ||
+ | </pre> | ||
+ | There are .soundref file (for each event) to specify bank end FMOD event of the sound. | ||
+ | |||
+ | Content of the sound_engine.soundref is: | ||
+ | <pre> | ||
+ | source="/sound/truck/peterbilt_579.bank#engine/engine" | ||
+ | </pre> | ||
+ | |||
The record<br>sound: ''"/sound/truck/peterbilt_579.bank"''<br>at the any engine configuration file assigns the sound bank to the engine. | The record<br>sound: ''"/sound/truck/peterbilt_579.bank"''<br>at the any engine configuration file assigns the sound bank to the engine. | ||
+ | |||
+ | == Engine Sound Position == | ||
+ | |||
+ | The 3D position of the engine sound is (by default) 1 m above the first axle of the truck.<br> | ||
+ | This position could be modified by the .soundref file. (see [[Documentation/Engine/Sound#Sound_reference_file|Sound reference file]]) | ||
== Engine Sound Example == | == Engine Sound Example == | ||
Visit the [[Documentation/Engine/Sound/Downloads|Downloads]] section to get template project or sound examples. | Visit the [[Documentation/Engine/Sound/Downloads|Downloads]] section to get template project or sound examples. |
Latest revision as of 08:38, 18 October 2020
Contents
Sounds - Truck Engine
The sound of the truck engine is very specific kind of the sounds.
Engine sound is very sensitive to be balanced between sound sources.
So there are a few rules for the engine sound:
- The each sound of the truck engine should be in the separate sound bank.
- There are only the four events and all should be implemented in the same bank.
- It is not recommended to combine events of different banks for the engine sound.
Engine Sound Events
- All events should be at the folder "engine" in the events browser.
- This events should exist in the bank:
engine/engine
engine/exhaust
engine/turbo (from 1.39)
engine/start_bad
Event "engine"
Event "engine" plays sound of the engine.
It has to be 3D event. The event should be routed to the "truck_engine" audio bus.
The event must be looped and its living cycle is controlled by "play" parameter (see bellow).
These event parameters must exist:
- engine/play
The parameter "play" control living cycle of the event:
value play = 1 means - sound is playing
value play = 0 means - sound should be stopped - engine/brake
the value is in the range <0 - 1> and represents the action of the motor brake - engine/load
the value is in the range <0 - 1>
value represents the motor load
value < 0.05 means idle engine sound - engine/rpm
the value is in the range <0 - 3000>
the value represents the number of engine revs per second
Event "exhaust"
Event "exhaust" plays sound of the exhaust.
It has to be 3D event. The event should be routed to the "truck_exhaust" audio bus.
The event must be looped and its living cycle is controlled by "play" parameter.
These event parameters must exist:
- exhaust/load
- exhaust/play
- exhaust/rpm
The purpose of the parameters is the same as for the "engine" event (see Event "engine").
Event "turbo"
Event "turbo" plays sound of the turbo.
It has to be 3D event. The event should be routed to the "truck_turbo" audio bus.
The event must be looped and its living cycle is controlled by "play" parameter.
These event parameters must exist:
- engine/turbo
the value is in the range <0 - 1> and represents the action of the turbo system
Event "start_bad"
Event "start_bad" plays sound of unsuccessful starting of the engine.
It has to be 3D event. The event should be routed to the "truck_engine" audio bus.
The event is one-shot sound (without loop).
There are no other parameters for the event.
It is possible to use randomization of the assets supported by FMOD Studio.
Engine Sound Configuration
The sound configuration of the engine sounds is stored in the "accessory_engine_data" data.
There is array "sounds" which contents specification for the mandatory events of the engine.
That means that each type of the engine can have assigned its own sound bank.
Example:
There are configuration files of engines for the "Peterbilt 579" at the folder "\def\vehicle\truck\peterbilt.579\engine".
Each engine include @include "sound.sui" file which contents indirect definition of the events:
sounds: 4 sounds[]: "engine|/def/vehicle/truck/peterbilt.579/engine/sound_engine.soundref" sounds[]: "exhaust|/def/vehicle/truck/peterbilt.579/engine/sound_exhaust.soundref" sounds[]: "start_bad|/def/vehicle/truck/peterbilt.579/engine/sound_start_bad.soundref" sounds[]: "turbo|/def/vehicle/truck/peterbilt.579/engine/sound_turbo.soundref"
There are .soundref file (for each event) to specify bank end FMOD event of the sound.
Content of the sound_engine.soundref is:
source="/sound/truck/peterbilt_579.bank#engine/engine"
The record
sound: "/sound/truck/peterbilt_579.bank"
at the any engine configuration file assigns the sound bank to the engine.
Engine Sound Position
The 3D position of the engine sound is (by default) 1 m above the first axle of the truck.
This position could be modified by the .soundref file. (see Sound reference file)
Engine Sound Example
Visit the Downloads section to get template project or sound examples.