Home Reference Source
import MP4Remuxer from 'hls.js/src/remux/mp4-remuxer.ts'
public class | source

MP4Remuxer

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public

config: HlsConfig

public
public
public
public
public

observer: HlsEventEmitter

public
Private Members
private
private

Method Summary

Public Methods
public
public

generateIS(audioTrack: DemuxedAudioTrack, videoTrack: DemuxedAvcTrack, timeOffset: undefined): {"tracks": *, "initPTS": *, "timescale": *}

public

getVideoStartPts(videoSamples: undefined): *

public

remux(audioTrack: DemuxedAudioTrack, videoTrack: DemuxedAvcTrack, id3Track: DemuxedMetadataTrack, textTrack: DemuxedUserdataTrack, timeOffset: number, accurateTimeOffset: boolean, flush: boolean, playlistType: PlaylistLevelType): RemuxerResult

public

remuxAudio(track: DemuxedAudioTrack, timeOffset: number, contiguous: boolean, accurateTimeOffset: boolean, videoTimeOffset: number): *

public

remuxEmptyAudio(track: DemuxedAudioTrack, timeOffset: number, contiguous: boolean, videoData: Fragment): *

public

remuxVideo(track: DemuxedAvcTrack, timeOffset: number, contiguous: boolean, audioTrackLength: number): *

public
public
public

resetTimeStamp(defaultTimeStamp: undefined)

Public Constructors

public constructor() source

Public Members

public ISGenerated: boolean source

public config: HlsConfig source

public isAudioContiguous: boolean source

public isVideoContiguous: boolean source

public nextAudioPts: * source

public nextAvcDts: * source

public observer: HlsEventEmitter source

public typeSupported: * source

Private Members

private _initDTS: number source

private _initPTS: number source

Public Methods

public destroy() source

public generateIS(audioTrack: DemuxedAudioTrack, videoTrack: DemuxedAvcTrack, timeOffset: undefined): {"tracks": *, "initPTS": *, "timescale": *} source

Params:

NameTypeAttributeDescription
audioTrack DemuxedAudioTrack
videoTrack DemuxedAvcTrack
timeOffset undefined

Return:

{"tracks": *, "initPTS": *, "timescale": *}

public getVideoStartPts(videoSamples: undefined): * source

Params:

NameTypeAttributeDescription
videoSamples undefined

Return:

*

public remux(audioTrack: DemuxedAudioTrack, videoTrack: DemuxedAvcTrack, id3Track: DemuxedMetadataTrack, textTrack: DemuxedUserdataTrack, timeOffset: number, accurateTimeOffset: boolean, flush: boolean, playlistType: PlaylistLevelType): RemuxerResult source

Params:

NameTypeAttributeDescription
audioTrack DemuxedAudioTrack
videoTrack DemuxedAvcTrack
id3Track DemuxedMetadataTrack
textTrack DemuxedUserdataTrack
timeOffset number
accurateTimeOffset boolean
flush boolean
playlistType PlaylistLevelType

Return:

RemuxerResult

public remuxAudio(track: DemuxedAudioTrack, timeOffset: number, contiguous: boolean, accurateTimeOffset: boolean, videoTimeOffset: number): * source

Params:

NameTypeAttributeDescription
track DemuxedAudioTrack
timeOffset number
contiguous boolean
accurateTimeOffset boolean
videoTimeOffset number

Return:

*

public remuxEmptyAudio(track: DemuxedAudioTrack, timeOffset: number, contiguous: boolean, videoData: Fragment): * source

Params:

NameTypeAttributeDescription
track DemuxedAudioTrack
timeOffset number
contiguous boolean
videoData Fragment

Return:

*

public remuxVideo(track: DemuxedAvcTrack, timeOffset: number, contiguous: boolean, audioTrackLength: number): * source

Params:

NameTypeAttributeDescription
track DemuxedAvcTrack
timeOffset number
contiguous boolean
audioTrackLength number

Return:

*

public resetInitSegment() source

public resetNextTimestamp() source

public resetTimeStamp(defaultTimeStamp: undefined) source

Params:

NameTypeAttributeDescription
defaultTimeStamp undefined