Home Reference Source
import TSDemuxer from 'hls.js/src/demux/tsdemuxer.ts'
public class | source

TSDemuxer

Static Method Summary

Static Public Methods
public static

createTrack(type: undefined, duration: undefined): DemuxedTrack

Creates a track model internal to demuxer used to drive remuxing input

public static
Static Private Methods
private static

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public
public
public
public

config: *

public
public
public
public
public
public
public
Private Members
private
private
private
private
private
private
private
private

Method Summary

Public Methods
public

decrypt(audioTrack: undefined, videoTrack: undefined, sampleAes: undefined): Promise

public

demux(data: Uint8Array, timeOffset: undefined, isSampleAes: undefined, flush: undefined): DemuxerResult

public

demuxSampleAes(data: undefined, decryptData: undefined, timeOffset: undefined): Promise

public
public

discardEPB(data: undefined): *

remove Emulation Prevention bytes from a RBSP

public

extractRemainingSamples(demuxResult: DemuxerResult)

public

flush(): *

public

pushAccessUnit(avcSample: undefined, avcTrack: undefined)

public
public

resetInitSegment(audioCodec: undefined, videoCodec: undefined, duration: undefined)

Initializes a new init segment on the demuxer/remuxer interface.

public
Private Methods
private
private
private
private
private
private
private

Static Public Methods

public static createTrack(type: undefined, duration: undefined): DemuxedTrack source

Creates a track model internal to demuxer used to drive remuxing input

Params:

NameTypeAttributeDescription
type undefined
duration undefined

Return:

DemuxedTrack

public static probe(data: undefined): boolean source

Params:

NameTypeAttributeDescription
data undefined

Return:

boolean

Static Private Methods

private static _syncOffset(data: undefined): * source

Params:

NameTypeAttributeDescription
data undefined

Return:

*

Public Constructors

public constructor() source

Public Members

public aacLastPTS: * source

public aacOverFlow: * source

public audioCodec: * source

public avcSample: * source

public config: * source

public contiguous: boolean source

public observer: * source

public pmtParsed: boolean source

public remainderData: * source

public sampleAes: * source

public typeSupported: * source

public videoCodec: * source

Private Members

private _audioTrack: * source

private _avcTrack: * source

private _duration: number source

private _id3Track: * source

private _initDTS: * source

private _initPTS: * source

private _pmtId: number source

private _txtTrack: * source

Public Methods

public decrypt(audioTrack: undefined, videoTrack: undefined, sampleAes: undefined): Promise source

Params:

NameTypeAttributeDescription
audioTrack undefined
videoTrack undefined
sampleAes undefined

Return:

Promise

public demux(data: Uint8Array, timeOffset: undefined, isSampleAes: undefined, flush: undefined): DemuxerResult source

Params:

NameTypeAttributeDescription
data Uint8Array
timeOffset undefined
isSampleAes undefined
flush undefined

Return:

DemuxerResult

public demuxSampleAes(data: undefined, decryptData: undefined, timeOffset: undefined): Promise source

Params:

NameTypeAttributeDescription
data undefined
decryptData undefined
timeOffset undefined

Return:

Promise

public destroy() source

public discardEPB(data: undefined): * source

remove Emulation Prevention bytes from a RBSP

Params:

NameTypeAttributeDescription
data undefined

Return:

*

public extractRemainingSamples(demuxResult: DemuxerResult) source

Params:

NameTypeAttributeDescription
demuxResult DemuxerResult

public flush(): * source

Return:

*

public pushAccessUnit(avcSample: undefined, avcTrack: undefined) source

Params:

NameTypeAttributeDescription
avcSample undefined
avcTrack undefined

public resetContiguity() source

public resetInitSegment(audioCodec: undefined, videoCodec: undefined, duration: undefined) source

Initializes a new init segment on the demuxer/remuxer interface. Needed for discontinuities/track-switches (or at stream start) Resets all internal track instances of the demuxer.

Params:

NameTypeAttributeDescription
audioCodec undefined
videoCodec undefined
duration undefined

public resetTimeStamp() source

Private Methods

private _getLastNalUnit(): * source

Return:

*

private _insertSampleInOrder(arr: undefined, data: undefined) source

Params:

NameTypeAttributeDescription
arr undefined
data undefined

private _parseAACPES(pes: undefined) source

Params:

NameTypeAttributeDescription
pes undefined

private _parseAVCNALu(array: undefined): Array source

Params:

NameTypeAttributeDescription
array undefined

Return:

Array

private _parseAVCPES(pes: undefined, last: undefined) source

Params:

NameTypeAttributeDescription
pes undefined
last undefined

private _parseID3PES(pes: undefined) source

Params:

NameTypeAttributeDescription
pes undefined

private _parseMPEGPES(pes: undefined) source

Params:

NameTypeAttributeDescription
pes undefined