fadeIn(duration, loop, marker)
Starts this sound playing (or restarts it if already doing so) and sets the volume to zero.
Then increases the volume from 0 to 1 over the duration specified.
At the end of the fade Sound.onFadeComplete is dispatched with this Sound object as the first parameter,
and the final volume (1) as the second parameter.
Parameters
Name | Type | Argument | Default | Description |
---|---|---|---|---|
duration | number | <optional> | 1000 | The time in milliseconds over which the Sound should fade in. |
loop | boolean | <optional> | false | Should the Sound be set to loop? Note that this doesn't cause the fade to repeat. |
marker | string | <optional> | (current marker) | The marker to start at; defaults to the current (last played) marker. To start playing from the beginning specify specify a marker of |
- Source code: sound/Sound.js (Line 924)
Please login to continue.