Interface PlayerConfig

An interface describing the available configuration options for a new player instance.

interface PlayerConfig {
    isQualitySupported?: ((q) => boolean);
    logLevel?: LogLevel;
    serviceWorker?: ServiceWorkerConfig;
    wasmBinary: string;
    wasmWorker: string;
}

Properties

isQualitySupported?: ((q) => boolean)

Note: This API is experimental and may change in a future release.

A function which keeps or removes a quality from the player. This function runs after the player filters the quality list internally. For example, after we remove qualities with unsupported codecs.

If true, the quality remains available.

If false, the quality will not be auto selected, cannot be manually selected, and will not be returned by Player.getQualities.

Type declaration

    • (q): boolean
    • Parameters

      Returns boolean

logLevel?: LogLevel

Deprecated

This can be set after construction using Player.setLogLevel.

serviceWorker?: ServiceWorkerConfig

Contains details about the service worker configuration.

wasmBinary: string

URL where the amazon-ivs-wasmworker.min.wasm file is hosted. This option is only supported by the NPM distribution of the player.

wasmWorker: string

URL where the amazon-ivs-wasmworker.min.js file is hosted. This option is only supported by the NPM distribution of the player.