setVolume

Description

Set the current volume, from 0 (no sound) to 1 (the maximum sound level).

Note that the volume set here is persisted even when loading another content. As such, this method can also be called when no content is currently playing.

Syntax

player.setVolume(volume);
  • arguments:

    1. volume number: Volume from 0 to 1.

Example

// set the full volume
player.setVolume(1);
Page List