Home Reference Source
import AudioStreamController from 'hls.js/src/controller/audio-stream-controller.ts'
public class | source

AudioStreamController

Extends:

src/controller/base-stream-controller.js~BaseStreamController → AudioStreamController

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public
public
public
public
public
public

levels: *

public
public
public
public
public
public
public

state: *

public
public
public
public
public
public

Method Summary

Public Methods
public
public
public

doTick()

public
public

loadFragment(frag: Fragment, trackDetails: LevelDetails, targetBufferTime: number)

public

onAudioTrackLoaded(event: undefined, data: TrackLoadedData)

public

onAudioTrackSwitching(event: undefined, data: AudioTrackSwitchingData)

public

onAudioTracksUpdated(event: undefined, undefined: AudioTracksUpdatedData)

public

onBufferCreated(event: undefined, data: BufferCreatedData)

public

onBufferFlushed(event: undefined, undefined: BufferFlushedData)

public
public

onError(event: undefined, data: ErrorData)

public

onFragBuffered(event: undefined, data: FragBufferedData)

public
public

onInitPtsFound(event: undefined, undefined: InitPTSFoundData)

public

onLevelLoaded(event: undefined, data: LevelLoadedData)

public
public
public
public

startLoad(startPosition: number)

Private Methods
private

_bufferInitSegment(tracks: TrackSet, frag: Fragment, chunkMeta: ChunkMetadata)

private

_handleFragmentLoadComplete(fragLoadedData: FragLoadedData)

private

_handleFragmentLoadProgress(data: FragLoadedData)

private

_handleTransmuxComplete(transmuxResult: TransmuxerResult)

private
private

Public Constructors

public constructor() source

Public Members

public audioSwitch: boolean source

public fragCurrent: * source

public fragLoadError: number source

public fragPrevious: * source

public lastCurrentTime: * source

public levelLastLoaded: * source

public levels: * source

public loadedmetadata: boolean source

public mainDetails: * source

public mediaBuffer: * source

public nextLoadPosition: * source

public startFragRequested: boolean source

public startPosition: * source

public state: * source

public trackId: number source

public transmuxer: * source

public videoBuffer: * source

public videoTrackCC: number source

public waitingData: * source

public waitingVideoCC: number source

Public Methods

public clearWaitingFragment() source

public completeAudioSwitch() source

public doTick() source

public doTickIdle() source

public loadFragment(frag: Fragment, trackDetails: LevelDetails, targetBufferTime: number) source

Params:

NameTypeAttributeDescription
frag Fragment
trackDetails LevelDetails
targetBufferTime number

public onAudioTrackLoaded(event: undefined, data: TrackLoadedData) source

Params:

NameTypeAttributeDescription
event undefined
data TrackLoadedData

public onAudioTrackSwitching(event: undefined, data: AudioTrackSwitchingData) source

Params:

NameTypeAttributeDescription
event undefined
data AudioTrackSwitchingData

public onAudioTracksUpdated(event: undefined, undefined: AudioTracksUpdatedData) source

Params:

NameTypeAttributeDescription
event undefined
undefined AudioTracksUpdatedData

public onBufferCreated(event: undefined, data: BufferCreatedData) source

Params:

NameTypeAttributeDescription
event undefined
data BufferCreatedData

public onBufferFlushed(event: undefined, undefined: BufferFlushedData) source

Params:

NameTypeAttributeDescription
event undefined
undefined BufferFlushedData

public onBufferReset() source

public onError(event: undefined, data: ErrorData) source

Params:

NameTypeAttributeDescription
event undefined
data ErrorData

public onFragBuffered(event: undefined, data: FragBufferedData) source

Params:

NameTypeAttributeDescription
event undefined
data FragBufferedData

public onHandlerDestroying() source

public onInitPtsFound(event: undefined, undefined: InitPTSFoundData) source

Params:

NameTypeAttributeDescription
event undefined
undefined InitPTSFoundData

public onLevelLoaded(event: undefined, data: LevelLoadedData) source

Params:

NameTypeAttributeDescription
event undefined
data LevelLoadedData

public onManifestLoading() source

public onMediaDetaching() source

public onTickEnd() source

public startLoad(startPosition: number) source

Params:

NameTypeAttributeDescription
startPosition number

Private Methods

private _bufferInitSegment(tracks: TrackSet, frag: Fragment, chunkMeta: ChunkMetadata) source

Params:

NameTypeAttributeDescription
tracks TrackSet
frag Fragment
chunkMeta ChunkMetadata

private _handleFragmentLoadComplete(fragLoadedData: FragLoadedData) source

Params:

NameTypeAttributeDescription
fragLoadedData FragLoadedData

private _handleFragmentLoadProgress(data: FragLoadedData) source

Params:

NameTypeAttributeDescription
data FragLoadedData

private _handleTransmuxComplete(transmuxResult: TransmuxerResult) source

Params:

NameTypeAttributeDescription
transmuxResult TransmuxerResult

private _registerListeners() source

private _unregisterListeners() source