Fix HLS writing an incomplete init segment for sparse segments, improve decoder config validation, fix getFirstTimestamp() for Inputs with zero-packet tracks, allow zero-track muxing for some formats that allow it, add new track metadata that allows you to specify the decoder config early (enables zero-packet tracks), fix trafIndices in sparse fragmented MP4s, fix assertion errors in MPEG-TS demuxer

This commit is contained in:
Vanilagy
2026-08-08 17:00:36 +02:00
parent 7ec538e175
commit 5b22c8c17d
23 changed files with 1433 additions and 204 deletions
+6 -1
View File
@@ -64,7 +64,7 @@ export class AdtsMuxer extends Muxer {
// First packet - determine input format from metadata
if (this.inputIsAdts === null) {
validateAudioChunkMetadata(meta);
validateAudioChunkMetadata(meta, track.source._codec);
const description = meta?.decoderConfig?.description;
@@ -119,6 +119,11 @@ export class AdtsMuxer extends Muxer {
async finalize() {
const release = await this.mutex.acquire(); // Required so that finalize() can't resolve before other calls
if (this.inputIsAdts === null) {
throw new Error('Cannot finalize an empty ADTS file: not a single packet was added.');
}
release();
}
}