Options
All
  • Public
  • Public/Protected
  • All
Menu

Class HTML5Audio

Hierarchy

  • HTML5Audio

Index

Constructors

Protected constructor

Properties

__autoPlay

__autoPlay: boolean

_audioElement

_audioElement: HTMLAudioElement

_buffered

_buffered: boolean

_gainTweenInterval

_gainTweenInterval: number

_hasError

_hasError: boolean

_initialized

_initialized: boolean

_isLoading

_isLoading: boolean

_loadListeners

_loadListeners: (() => void)[]

_staticSePath

_staticSePath: boolean

_tweenGain

_tweenGain: number

_tweenGainStep

_tweenGainStep: number

_tweenTargetGain

_tweenTargetGain: number

_unlocked

_unlocked: boolean

_volume

_volume: number

url

url: string

[read-only] The url of the audio file.

property

url

volume

volume: number

The volume of the audio.

property

volume

Methods

clear

  • clear(): void

fadeIn

  • fadeIn(duration: number): void

fadeOut

  • fadeOut(duration: number): void

initialize

  • initialize(): void

isError

  • isError(): boolean

isPlaying

  • isPlaying(): boolean

isReady

  • isReady(): boolean

play

  • play(loop: boolean, offset: number): void
  • Plays the audio.

    static
    method

    play

    Parameters

    • loop: boolean

      Whether the audio data play in a loop

    • offset: number

      The start position to play in seconds

    Returns void

seek

  • seek(): void

setStaticSe

  • setStaticSe(url: string): void

setup

  • setup(url: string): void

stop

  • stop(): void

Generated using TypeDoc