Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface MediaSource

This Media Source Extensions API interface represents a source of media data for an HTMLMediaElement object. A MediaSource object can be attached to a HTMLMediaElement to be played in the user agent.

Hierarchy

Index

Properties

activeSourceBuffers: SourceBufferList
duration: number
onsourceclose: null | ((this: MediaSource, ev: Event) => any)
onsourceended: null | ((this: MediaSource, ev: Event) => any)
onsourceopen: null | ((this: MediaSource, ev: Event) => any)
readyState: ReadyState
sourceBuffers: SourceBufferList

Methods

  • Parameters

    • type: string

    Returns SourceBuffer

  • clearLiveSeekableRange(): void
  • Returns void

  • dispatchEvent(event: Event): boolean
  • Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise.

    Parameters

    Returns boolean

  • endOfStream(error?: "network" | "decode"): void
  • Parameters

    • Optional error: "network" | "decode"

    Returns void

  • Parameters

    Returns void

  • setLiveSeekableRange(start: number, end: number): void
  • Parameters

    • start: number
    • end: number

    Returns void

Generated using TypeDoc