Page History
Section | ||||||||
---|---|---|---|---|---|---|---|---|
|
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Play |
Begin playing the video at the (optionally) specified time.
Code Block | ||
---|---|---|
| ||
player.play(time); |
Parameter | Data Type | Description |
---|---|---|
time | integer | optional: the video should begin playing from this time (in seconds) default = null |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Pause |
Pauses the video; there is no effect if the Player is already paused.
Code Block | ||
---|---|---|
| ||
player.pause(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Stop |
Stops the video; no effect if the Player is already stopped.
Code Block | ||
---|---|---|
| ||
player.stop(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Forward |
Fast forward the video by the number of milliseconds given.
Code Block | ||
---|---|---|
| ||
player.forward(millis); |
Parameter | Data Type | Description |
---|---|---|
millis | integer | interval in milliseconds |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Rewind |
Rewind the video by the number of milliseconds given.
Code Block | ||
---|---|---|
| ||
player.rewind(millis); |
Parameter | Data Type | Description |
---|---|---|
millis | integer | interval in milliseconds |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Set Volume |
Sets the volume of a video to a specified level.
Code Block | ||
---|---|---|
| ||
player.setVolume(volume); |
Parameter | Data Type | Description |
---|---|---|
volume | float | level to set the volume of the video to (range from 0.0 to 1.0 with a step size of 0.1) |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Toggle Mute |
Toggles the audio on or off.
Code Block | ||
---|---|---|
| ||
player.toggleMute(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Get Current Time |
Returns the current video time in seconds.
Code Block | ||
---|---|---|
| ||
player.getCurrentTime(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Get Duration |
Returns the duration of the current video in seconds.
Code Block | ||
---|---|---|
| ||
player.getDuration(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Get Buffered Time |
Returns the total time of the video that has been buffered in seconds.
Code Block | ||
---|---|---|
| ||
player.getBufferedTime(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Get Video Title |
Returns the title of the current video. (only for native player)
Code Block | ||
---|---|---|
| ||
player.getApi("metaData").getVideoTitle(); |
Anchor | ||||
---|---|---|---|---|
|
Panel | ||||
---|---|---|---|---|
| ||||
Switch Video |
Load a video specified by ID.
Code Block | ||
---|---|---|
| ||
player.switchVideo(videoId); |
Parameter | Data Type | Description |
---|---|---|
videoId | string | ID of the video to be loaded |