Create a free ticket and our support team will provide you necessary assistance.
| Method | Returns | Return type | Description |
|---|---|---|---|
| initialize() | - | void | Starts the player. This method will be called automatically by the constructor unless wait parameter in the constructor has been set to false. |
| getInstanceID() | Instance ID number | number | The method returns instance ID of the player. |
| getLibrary() | StormLibrary Object | StormLibrary | The method returns main StormLibrary object used by the player. |
| setPlayerConfig(config:StormPlayerConfig) | - | void | Updates player config. |
| setStreamConfig(config:StormStreamConfig) | - | void | Updates stream config. |
| setSize(width:number | string, height:number | string) | - | void | The method sets a new width and height for the player. The values can be given as a number (in which case they are treated as the number of pixels), or as a string ending with "px" (this will also be the number of pixels) or "%", where the number is treated as a percentage of the parent container's value. |
| setWidth(width:number | string) | - | void | The method sets a new width for the player. The value can be given as a number (in which case it is treated as the number of pixels), or as a string ending with "px" (this will also be the number of pixels) or "%", where the number is treated as a percentage of the parent container's value. |
| setHeight(height:number | string) | - | void | The method sets a new height for the player. The value can be given as a number (in which case it is treated as the number of pixels), or as a string ending with "px" (this will also be the number of pixels) or "%", where the number is treated as a percentage of the parent container's value. |
| getWidth() | Player width | number | Returns player width in pixels. |
| getHeight() | Player height | number | Returns player height in pixels. |
| setTitle(title:string) | - | void | The method allows to specify the title displayed in the upper-right corner of the player. |
| setSubtitle(subtitle:string) | - | void | The method allows to specify the subtitle displayed in the upper-right corner of the player (below the title). |
| getPlayerConfig() | Object containing player settings | Object | This method returns an object containing all player preferences (related to its GUI). |
| addCuePoint(title:string, time:number) | - | void | This method adds a CUE point to the player timeline with a given title. |
| removeCuePoint(time:number) | - | void | This method removes a CUE point based on its time. |
| addEventListener(eventName:string, callback:function) | - | void | Registers an event with the player object. Whenever a registered event occurs, player will call a predefined function provided. |
| removeEventListener(eventName:string, callback:function) | - | void | Removes event listener from the player. |
Create a free ticket and our support team will provide you necessary assistance.