Interface: shaka.device.IDevice

Members

BrowserEngine :string

Type:
  • string
Properties:
Name Value Type Description
CHROMIUM CHROMIUM string
EDGE EDGE string
GECKO GECKO string
WEBKIT WEBKIT string
UNKNOWN UNKNOWN string
Source:

DeviceType :string

Type:
  • string
Properties:
Name Value Type Description
DESKTOP DESKTOP string
MOBILE MOBILE string
TV TV string
VR VR string
CONSOLE CONSOLE string
CAST CAST string
Source:

Methods

adjustConfig(config) → {shaka.extern.PlayerConfiguration}

Adjusts player configuration with device specific tweaks. Changes are done in-place and the same object is returned.
Parameters:
Name Type Description
config shaka.extern.PlayerConfiguration
Source:
Returns:
Type
shaka.extern.PlayerConfiguration

createMediaKeysWhenCheckingSupport() → {boolean}

Source:
Returns:
Type
boolean

detectMaxHardwareResolution() → {Promise.<shaka.extern.Resolution>}

Detect the maximum resolution that the platform's hardware can handle.
Source:
Returns:
Type
Promise.<shaka.extern.Resolution>

disableHEVCSupport() → {boolean}

Source:
Returns:
Type
boolean

getDeviceName() → {string}

Friendly device name.
Source:
Returns:
Type
string

getHdrLevel(preferHLG) → {string}

Check the current HDR level supported by the screen.
Parameters:
Name Type Description
preferHLG boolean
Source:
Returns:
Type
string

getVersion() → {number}

Version of device or null if unknown.
Source:
Returns:
Type
number

insertEncryptionDataBeforeClear() → {boolean}

Indicates should the encryption data be inserted before or after the clear data in the init segment.
Source:
Returns:
Type
boolean

misreportAC3UsingDrm() → {boolean}

Source:
Returns:
Type
boolean

misreportsSupportForPersistentLicenses() → {boolean}

Source:
Returns:
Type
boolean

rejectCodecs() → {Array.<string>}

Lists all codecs that should be rejected by MediaSource.
Source:
Returns:
Type
Array.<string>

requiresClearAndEncryptedInitSegments() → {boolean}

Returns true if the platform requires both clear & encryption information in clear init segments. For such platforms, MediaSourceEngine will attempt to work around a lack of such info by inserting fake information into initialization segments. It is called only when requiresEncryptionInfoInAllInitSegments() is also true and works as the extension of it.
Source:
See:
Returns:
Type
boolean

requiresEC3InitSegments() → {boolean}

Returns true if the platform requires AC-3 signalling in init segments to be replaced with EC-3 signalling. For such platforms, MediaSourceEngine will attempt to work around it by inserting fake EC-3 signalling into initialization segments.
Source:
Returns:
Type
boolean

requiresEncryptionInfoInAllInitSegments(keySystemnullable, contentTypenullable) → {boolean}

Returns true if the platform requires encryption information in all init segments. For such platforms, MediaSourceEngine will attempt to work around a lack of such info by inserting fake encryption information into initialization segments.
Parameters:
Name Type Attributes Description
keySystem string <nullable>
contentType string <nullable>
Source:
See:
Returns:
Type
boolean

requiresTfhdFix(contentType) → {boolean}

Parameters:
Name Type Description
contentType string
Source:
Returns:
Type
boolean

returnLittleEndianUsingPlayReady() → {boolean}

Source:
Returns:
Type
boolean

seekDelay() → {number}

On some platforms, the act of seeking can take a significant amount of time, so we need to delay a seek.
Source:
Returns:
Type
number

shouldAvoidUseTextDecoderEncoder() → {boolean}

Indicates whether or not to use window.TextDecoder and window.TextEncoder even if they are available
Source:
Returns:
Type
boolean

shouldOverrideDolbyVisionCodecs() → {boolean}

Checks should Dolby Vision codecs be overridden to their H.264 and H.265 equivalents.
Source:
Returns:
Type
boolean

supportsAirPlay() → {boolean}

Source:
Returns:
Type
boolean

supportsEncryptionSchemePolyfill() → {boolean}

Source:
Returns:
Type
boolean

supportsMediaCapabilities() → {boolean}

Source:
Returns:
Type
boolean

supportsMediaSource() → {boolean}

Check if the current platform supports media source. We assume that if the current platform supports media source, then we can use media source as per its design.
Source:
Returns:
Type
boolean

supportsMediaType(mimeType) → {boolean}

Returns true if the media type is supported natively by the platform.
Parameters:
Name Type Description
mimeType string
Source:
Returns:
Type
boolean

supportsOfflineStorage() → {boolean}

Checks does the platform supports offline storage by IDB.
Source:
Returns:
Type
boolean

supportsSequenceMode() → {boolean}

Returns true if the platform supports SourceBuffer "sequence mode".
Source:
Returns:
Type
boolean

supportsServerCertificate() → {boolean}

Source:
Returns:
Type
boolean

supportsSmoothCodecSwitching() → {boolean}

Returns if codec switching SMOOTH is known reliable device support. Some devices are known not to support SourceBuffer.changeType well. These devices should use the reload strategy. If a device reports that it supports but supports it unreliably it should be disallowed in this method.
Source:
Returns:
Type
boolean

supportStandardVP9Checking() → {boolean}

Source:
Returns:
Type
boolean