Open ThaUnknown opened 1 year ago
EbmlStreamDecoder will not output any data if the stream starts in the middle of a file ex:
import { createReadStream } from 'node:fs' import { EbmlStreamDecoder } from 'ebml-stream' const decoder = new EbmlStreamDecoder({ bufferTagIds: [ EbmlTagId.TimecodeScale, EbmlTagId.Tracks, EbmlTagId.BlockGroup, EbmlTagId.AttachedFile ] }) decoder.on('data', console.log) // never ran const stream = createReadStream('./video.mkv', { start: 2392064, end: 23920640 }) stream.on('data', data => decoder.write(data)) stream.pipe(subtitle).pipe(devnull())
EbmlStreamDecoder will not output any data if the stream starts in the middle of a file ex: