Howto:Add sound effects to aircraft: Difference between revisions

Jump to navigation Jump to search
→‎Configuration tags: explaining meaning/purpose of pitch & volume sections
(Code sample did not match sim gear source code.)
(→‎Configuration tags: explaining meaning/purpose of pitch & volume sections)
Line 148: Line 148:
: Currently there may be up to 5 volume and up to 5 pitch definitions defined within one sound event.
: Currently there may be up to 5 volume and up to 5 pitch definitions defined within one sound event.


: Normally all offset values are added together and the results after property calculations will be multiplied.
: There are two important results from each <volume> and <pitch> section: the offset and the value. Normally all offset values from the different volume/pitch are added together to create the total offset.  The values from each <volume> or <pitch> section are multiplied together to create an final value.  Then the volume (or pitch, respectively) is set to total offset + final value.


: A special condition occurs when the value of factor is negative, in which case the offset doesn't get added to the other offset values but instead will be used in the multiplication section.
: A special condition occurs when the value of factor is negative, in which case the offset doesn't get added to the other offset values but instead will be used in the multiplication section.


: Notice that pitch final output is clamped 0 to 2. For pitch 1 means no change in pitch and 2 is maximum pitch increase. Offset is defaulting to 1.
: Pitch final output can range from 0 to 2. 1 represents the original pitch of the sound file.  Offset defaults to 1, meaning that if no specific <pitch> parameters are given the file will be played at its original pitch.
 
: Volume final output can range from 0 to 1. 1 represents full volume and 0 is silence.


; <code>&lt;property&gt;</code>
; <code>&lt;property&gt;</code>
482

edits

Navigation menu