mediabunny 1.7.1 → 1.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundles/mediabunny.cjs +10 -2
- package/dist/bundles/mediabunny.min.cjs +1 -1
- package/dist/bundles/mediabunny.min.mjs +1 -1
- package/dist/bundles/mediabunny.mjs +10 -2
- package/dist/mediabunny.d.ts +3 -2
- package/dist/modules/src/isobmff/isobmff-demuxer.d.ts.map +1 -1
- package/dist/modules/src/isobmff/isobmff-demuxer.js +5 -0
- package/dist/modules/src/media-sink.d.ts.map +1 -1
- package/dist/modules/src/media-sink.js +7 -1
- package/dist/modules/src/media-source.d.ts +3 -2
- package/dist/modules/src/media-source.d.ts.map +1 -1
- package/dist/modules/src/media-source.js +3 -2
- package/dist/modules/src/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/isobmff/isobmff-demuxer.ts +6 -0
- package/src/media-sink.ts +7 -1
- package/src/media-source.ts +3 -2
|
@@ -9074,6 +9074,10 @@ ${cue.notes ?? ""}`;
|
|
|
9074
9074
|
this.customDecoderCallSerializer = new CallSerializer();
|
|
9075
9075
|
this.customDecoderQueueSize = 0;
|
|
9076
9076
|
const sampleHandler = (sample) => {
|
|
9077
|
+
if (sample.numberOfFrames === 0) {
|
|
9078
|
+
sample.close();
|
|
9079
|
+
return;
|
|
9080
|
+
}
|
|
9077
9081
|
const sampleRate = decoderConfig.sampleRate;
|
|
9078
9082
|
sample.setTimestamp(Math.round(sample.timestamp * sampleRate) / sampleRate);
|
|
9079
9083
|
onSample(sample);
|
|
@@ -10663,7 +10667,8 @@ ${cue.notes ?? ""}`;
|
|
|
10663
10667
|
super(codec);
|
|
10664
10668
|
}
|
|
10665
10669
|
/**
|
|
10666
|
-
* Adds an encoded packet to the output video track.
|
|
10670
|
+
* Adds an encoded packet to the output video track. Packets must be added in *decode order*, while a packet's
|
|
10671
|
+
* timestamp must be its *presentation timestamp*. B-frames are handled automatically.
|
|
10667
10672
|
*
|
|
10668
10673
|
* @param meta - Additional metadata from the encoder. You should pass this for the first call, including a valid
|
|
10669
10674
|
* decoder config.
|
|
@@ -11100,7 +11105,7 @@ ${cue.notes ?? ""}`;
|
|
|
11100
11105
|
super(codec);
|
|
11101
11106
|
}
|
|
11102
11107
|
/**
|
|
11103
|
-
* Adds an encoded packet to the output audio track.
|
|
11108
|
+
* Adds an encoded packet to the output audio track. Packets must be added in *decode order*.
|
|
11104
11109
|
*
|
|
11105
11110
|
* @param meta - Additional metadata from the encoder. You should pass this for the first call, including a valid
|
|
11106
11111
|
* decoder config.
|
|
@@ -13256,6 +13261,9 @@ ${cue.notes ?? ""}`;
|
|
|
13256
13261
|
const sampleIndex = this.metadataReader.readU32() - 1;
|
|
13257
13262
|
track.sampleTable.keySampleIndices.push(sampleIndex);
|
|
13258
13263
|
}
|
|
13264
|
+
if (track.sampleTable.keySampleIndices[0] !== 0) {
|
|
13265
|
+
track.sampleTable.keySampleIndices.unshift(0);
|
|
13266
|
+
}
|
|
13259
13267
|
}
|
|
13260
13268
|
;
|
|
13261
13269
|
break;
|