Media_Amplify ( container; factor {; limit } )
Media_Amplify amplifies the audio waveform of a sound file, adjusting its volume.
Parameter | Description |
---|---|
container | Location of the sound. |
factor | (Any number) the amplification factor that multiplies the audio waveform, changing its playback volume. |
limit | Optional parameter. The peak or limit to the greatest amplification of the audio waveform. |
The result must be returned into a container field.
Essentially, Media_Amplify multiplies the audio waveform (factor) without exceeding the limit value.
Setting the factor to “2” will double the amplitude, for example. In other words, it multiplies every point along the audio wave by two.
If you also set the limit to “1”, for example, after amplification no point on the waveform will exceed the highest point of the original wave form.
A good way to become more familiar with this function is to run the function with several values, and follow by calling the Media_DrawWaveform function to get a visual representation of the changes.
Use Media_GetLastError to check for any errors of this function.