logo

THEOplayer > TypedSource

TypedSource interface

Inherits from BaseSource. See parent page for inherited properties and methods.

Represents a media resource characterized by a URL to the resource and optionally information about the resource.

Signature:

export interface TypedSource extends BaseSource 

Properties

Property

Type

Description

contentProtection (optional)

DRMConfiguration

The content protection parameters for the media resource.

drm (optional)

DRMConfiguration

The content protection parameters for the media resource.

src (optional)

string

The source URL of the media resource.

ssai (optional)

ServerSideAdInsertionConfiguration

The Server-side Ad Insertion parameters for the media resource.

type (optional)

string

The content type (MIME type) of the media resource, represented by a value from the following list:
- 'application/dash+xml': The media resource is an MPEG-DASH stream.
- 'application/x-mpegURL' or 'application/vnd.apple.mpegurl': The media resource is an HLS stream.
- 'video/mp4', 'video/webm' and other formats: The media resource should use native HTML5 playback if supported by the browser.
- 'application/vnd.theo.hesp+json': The media resource is an HESP stream.

Property Details

contentProtection

The content protection parameters for the media resource.

Signature:

contentProtection?: DRMConfiguration;

Remarks


- Available since v2.15.0.

drm

Warning: This API is deprecated.

Superseded by TypedSource.contentProtection.

The content protection parameters for the media resource.

Signature:

drm?: DRMConfiguration;

src

The source URL of the media resource.

Signature:

src?: string;

Remarks


- Required if the ssai property is absent.
- Available since v2.4.0.

ssai

The Server-side Ad Insertion parameters for the media resource.

Signature:

ssai?: ServerSideAdInsertionConfiguration;

Remarks


- Available since v2.12.0.

type

The content type (MIME type) of the media resource, represented by a value from the following list:
- 'application/dash+xml': The media resource is an MPEG-DASH stream.
- 'application/x-mpegURL' or 'application/vnd.apple.mpegurl': The media resource is an HLS stream.
- 'video/mp4', 'video/webm' and other formats: The media resource should use native HTML5 playback if supported by the browser.
- 'application/vnd.theo.hesp+json': The media resource is an HESP stream.

Signature:

type?: string;

Remarks


- Available since v2.4.0.

github
Make sure to follow us on GitHub!
THEO-logo-white
twitter
facebook
linkedin
Copyright © 2022. All Rights Reserved.
Leuven
New York
Singapore
Barcelona