THEOplayer > PlayerConfiguration
Describes a player's configuration.
Signature:
export interface PlayerConfiguration
Property |
Type |
Description |
---|---|---|
abr (optional) |
The player's ABR configuration. |
|
ads (optional) |
The ads configuration for the player. |
|
allowMixedContent (optional) |
|
Whether mixed HTTP/HTTPS content is allowed. |
allowNativeFullscreen (optional) |
|
Whether the native video element's fullscreen should be used whenever THEOplayer's fullscreen is unsupported. |
analytics (optional) |
List of analytics configurations for the player. |
|
cast (optional) |
The cast configuration for the player. |
|
hideDeprecationWarnings (optional) |
|
If set, hides all deprecation warnings. |
hlsDateRange (optional) |
|
Whether date ranges will be parsed from HLS manifests. |
isEmbeddable (optional) |
|
Whether THEOplayer will be used in an iframe. |
libraryLocation (optional) |
|
The directory in which the THEOplayer library worker files are located. These worker files are theoplayer.d.js, theoplayer.e.js, theoplayer.p.js. |
license (optional) |
|
The license for the player |
licenseUrl (optional) |
|
The url to fetch the license for the player |
liveOffset (optional) |
|
The offset in seconds used to determine the live point. This live point is the end of the manifest minus the provided offset. |
mutedAutoplay (optional) |
The muted autoplay policy. |
|
persistVolume (optional) |
|
Whether volume preferences will be persisted across player sessions. |
retainPlaybackRateOnSourceChange (optional) |
|
Whether |
retryConfiguration (optional) |
The retry configuration for the player. |
|
verizonMedia (optional) |
The Verizon Media configuration for the player. |
|
vr (optional) |
The vr configuration for the player. |
The player's ABR configuration.
Signature:
abr?: SourceAbrConfiguration;
- Available since v3.1.0.
- Used for DASH and LL-HLS streams.
The ads configuration for the player.
Signature:
ads?: AdsConfiguration;
Whether mixed HTTP/HTTPS content is allowed.
Signature:
allowMixedContent?: boolean;
- Available since 2.22.0.
- By default, the player assumes that it cannot load HTTP URLs when inside a HTTPS page because of mixed content restrictions. Therefore, the player will automatically convert HTTP URLs to HTTPS before loading them.
- When this option is set to true, the player may assume that mixed content is allowed on the current platform, and will not automatically convert HTTP URLs to HTTPS.
Whether the native video element's fullscreen should be used whenever THEOplayer's fullscreen is unsupported.
Signature:
allowNativeFullscreen?: boolean;
- Available since 2.21.0.
- It should be considered for older Android devices and iOS.
- It is limited to the platform's controls, custom UI and interactions are not possible.
- Together with the Google IMA integration, media preloading is unavailable on iOS devices.
- Together with the Google IMA integration, the current time is set to the live point when returning to the content after an ad.
List of analytics configurations for the player.
Signature:
analytics?: AnalyticsDescription[];
Multiple integrations can be enabled at once.
The cast configuration for the player.
Signature:
cast?: CastConfiguration;
If set, hides all deprecation warnings.
Signature:
hideDeprecationWarnings?: boolean;
- Available since v5.5.0.
Whether date ranges will be parsed from HLS manifests.
Signature:
hlsDateRange?: boolean;
Available since 2.61.
Whether THEOplayer will be used in an iframe.
Signature:
isEmbeddable?: boolean;
The directory in which the THEOplayer library worker files are located. These worker files are theoplayer.d.js, theoplayer.e.js, theoplayer.p.js.
Signature:
libraryLocation?: string;
- This parameter is required when using a HLS source and has no default.
'/lib/theoplayer/'
The license for the player
Signature:
license?: string;
The url to fetch the license for the player
Signature:
licenseUrl?: string;
The offset in seconds used to determine the live point. This live point is the end of the manifest minus the provided offset.
Signature:
liveOffset?: number;
- Available since v2.35.0.
The muted autoplay policy.
Signature:
mutedAutoplay?: MutedAutoplayConfiguration;
- The muted autoplay policy is impacted by this property and SourceConfiguration.mutedAutoplay.
Whether volume preferences will be persisted across player sessions.
Signature:
persistVolume?: boolean;
Available since 2.27.0.
Whether playbackRate
is retained across sources. When false
, playbackRate
will be reset to 1 on each source change. Defaults to false
.
Signature:
retainPlaybackRateOnSourceChange?: boolean;
The retry configuration for the player.
Signature:
retryConfiguration?: RetryConfiguration;
The Verizon Media configuration for the player.
Signature:
verizonMedia?: VerizonMediaConfiguration;
The vr configuration for the player.
Signature:
vr?: VRPlayerConfiguration;