Interface: shaka.extern.AdaptationSetCriteria

Methods

configure(config)

Sets the AdaptationSetCriteria configuration.
Parameters:
Name Type Description
config shaka.extern.AdaptationSetCriteria.Configuration
Source:

create(variantsnon-null) → {shaka.media.AdaptationSet}

Take a set of variants, and return a subset of variants that can be adapted between.
Parameters:
Name Type Description
variants Array<shaka.extern.Variant>
Source:
Returns:
Type
shaka.media.AdaptationSet

getConfiguration() → {shaka.extern.AdaptationSetCriteria.Configuration}

Gets the current AdaptationSetCriteria configuration.
Source:
Returns:
Type
shaka.extern.AdaptationSetCriteria.Configuration

getLastAdaptationSet() → {shaka.media.AdaptationSet}

Return the result of last create call.
Source:
Returns:
Type
shaka.media.AdaptationSet

Type Definitions

Configuration

Type:
  • {preferredAudio: !Array<!shaka.extern.AudioPreference>, preferredVideo: !Array<!shaka.extern.VideoPreference>, language: string, role: string, videoRole: string, channelCount: number, hdrLevel: string, spatialAudio: boolean, videoLayout: string, audioLabel: string, videoLabel: string, preferredAudioCodecs: !Array<string>, preferredAudioChannelCount: number, codecSwitchingStrategy: shaka.config.CodecSwitchingStrategy, audioCodec: string, activeAudioCodec: string, activeAudioChannelCount: number, keySystem: string}
Properties:
Name Type Description
preferredAudio Array<!shaka.extern.AudioPreference> An ordered list of audio preferences used to filter variants.
preferredVideo Array<!shaka.extern.VideoPreference> An ordered list of video preferences used to filter variants.
language string Deprecated. Use preferredAudio instead. The language used to filter variants. Populated from preferredAudio[0].language.
role string Deprecated. Use preferredAudio instead. The adaptation audio role used to filter variants. Populated from preferredAudio[0].role.
videoRole string Deprecated. Use preferredVideo instead. The adaptation video role used to filter variants. Populated from preferredVideo[0].role.
channelCount number Deprecated. Use preferredAudio instead. The audio channel count used to filter variants. Populated from preferredAudio[0].channelCount.
hdrLevel string Deprecated. Use preferredVideo instead. The HDR level used to filter variants. Populated from preferredVideo[0].hdrLevel.
spatialAudio boolean Deprecated. Use preferredAudio instead. Whether should prefer audio tracks with spatial audio. Populated from preferredAudio[0].spatialAudio.
videoLayout string Deprecated. Use preferredVideo instead. The video layout used to filter variants. Populated from preferredVideo[0].layout.
audioLabel string Deprecated. Use preferredAudio instead. The audio label used to filter variants. Populated from preferredAudio[0].label.
videoLabel string Deprecated. Use preferredVideo instead. The video label used to filter variants. Populated from preferredVideo[0].label.
preferredAudioCodecs Array<string> Deprecated. Use preferredAudio instead. The ordered list of audio codecs to filter variants. Populated from preferredAudio[*].codec.
preferredAudioChannelCount number Deprecated. Use preferredAudio instead. The preferred audio channel count to filter variants. Populated from preferredAudio[0].channelCount.
codecSwitchingStrategy shaka.config.CodecSwitchingStrategy The codec switching strategy used to filter variants.
audioCodec string The audio codec used to filter variants.
activeAudioCodec string The active audio codec used to filter variants.
activeAudioChannelCount number The active audio channel count used to filter variants.
keySystem string Current used key system or empty if not used.
Source:

Factory

A factory for creating the AdaptationSetCriteria.
Type:
  • function(): !shaka.extern.AdaptationSetCriteria
Source: