mirror of
https://github.com/arcodange-org/mediabunny.git
synced 2026-10-09 16:53:47 +02:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
72ed933bf4 | ||
|
|
ef3b53ff8a | ||
|
|
ac8baa4873 |
@@ -98,6 +98,7 @@ const sponsors = {
|
|||||||
{ image: 'https://avatars.githubusercontent.com/u/30229596', name: 'Pablo Bonilla', url: 'https://github.com/devPablo' },
|
{ image: 'https://avatars.githubusercontent.com/u/30229596', name: 'Pablo Bonilla', url: 'https://github.com/devPablo' },
|
||||||
{ image: 'https://avatars.githubusercontent.com/u/58149663', name: 'H7GhosT', url: 'https://github.com/H7GhosT' },
|
{ image: 'https://avatars.githubusercontent.com/u/58149663', name: 'H7GhosT', url: 'https://github.com/H7GhosT' },
|
||||||
{ image: 'https://avatars.githubusercontent.com/u/91711202', name: 'ihasq', url: 'https://github.com/ihasq' },
|
{ image: 'https://avatars.githubusercontent.com/u/91711202', name: 'ihasq', url: 'https://github.com/ihasq' },
|
||||||
|
{ image: 'https://avatars.githubusercontent.com/u/61233224', name: 'Allwhy', url: 'https://github.com/Allwhy' },
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -129,6 +129,8 @@ const renderObject = (object: Record<string, unknown>) => {
|
|||||||
listItem.removeChild(loadingSpan);
|
listItem.removeChild(loadingSpan);
|
||||||
listItem.appendChild(renderValue(resolvedValue));
|
listItem.appendChild(renderValue(resolvedValue));
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
|
console.error(error);
|
||||||
|
|
||||||
// Show the promise error
|
// Show the promise error
|
||||||
listItem.removeChild(loadingSpan);
|
listItem.removeChild(loadingSpan);
|
||||||
const errorSpan = document.createElement('span');
|
const errorSpan = document.createElement('span');
|
||||||
|
|||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "mediabunny",
|
"name": "mediabunny",
|
||||||
"version": "1.4.0",
|
"version": "1.4.2",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "mediabunny",
|
"name": "mediabunny",
|
||||||
"version": "1.4.0",
|
"version": "1.4.2",
|
||||||
"license": "MPL-2.0",
|
"license": "MPL-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/dom-mediacapture-transform": "^0.1.11",
|
"@types/dom-mediacapture-transform": "^0.1.11",
|
||||||
|
|||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "mediabunny",
|
"name": "mediabunny",
|
||||||
"author": "Vanilagy",
|
"author": "Vanilagy",
|
||||||
"version": "1.4.0",
|
"version": "1.4.2",
|
||||||
"description": "Pure TypeScript media toolkit for reading, writing, and converting media files, directly in the browser.",
|
"description": "Pure TypeScript media toolkit for reading, writing, and converting media files, directly in the browser.",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/bundles/mediabunny.cjs",
|
"main": "./dist/bundles/mediabunny.cjs",
|
||||||
|
|||||||
@@ -368,6 +368,13 @@ export class MatroskaDemuxer extends Demuxer {
|
|||||||
this.readContiguousElements(this.metadataReader, size);
|
this.readContiguousElements(this.metadataReader, size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this.currentSegment.timestampScale === -1) {
|
||||||
|
// TimestampScale element is missing. Technically an invalid file, but let's default to the typical value,
|
||||||
|
// which is 1e6.
|
||||||
|
this.currentSegment.timestampScale = 1e6;
|
||||||
|
this.currentSegment.timestampFactor = 1e9 / 1e6;
|
||||||
|
}
|
||||||
|
|
||||||
// Put default tracks first
|
// Put default tracks first
|
||||||
this.currentSegment.tracks.sort((a, b) => Number(b.isDefault) - Number(a.isDefault));
|
this.currentSegment.tracks.sort((a, b) => Number(b.isDefault) - Number(a.isDefault));
|
||||||
|
|
||||||
|
|||||||
@@ -236,6 +236,7 @@ export class VideoSample {
|
|||||||
return new VideoSample(this._data.clone(), {
|
return new VideoSample(this._data.clone(), {
|
||||||
timestamp: this.timestamp,
|
timestamp: this.timestamp,
|
||||||
duration: this.duration,
|
duration: this.duration,
|
||||||
|
rotation: this.rotation,
|
||||||
});
|
});
|
||||||
} else if (this._data instanceof Uint8Array) {
|
} else if (this._data instanceof Uint8Array) {
|
||||||
return new VideoSample(this._data.slice(), {
|
return new VideoSample(this._data.slice(), {
|
||||||
@@ -245,6 +246,7 @@ export class VideoSample {
|
|||||||
timestamp: this.timestamp,
|
timestamp: this.timestamp,
|
||||||
duration: this.duration,
|
duration: this.duration,
|
||||||
colorSpace: this.colorSpace,
|
colorSpace: this.colorSpace,
|
||||||
|
rotation: this.rotation,
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
return new VideoSample(this._data, {
|
return new VideoSample(this._data, {
|
||||||
@@ -254,6 +256,7 @@ export class VideoSample {
|
|||||||
timestamp: this.timestamp,
|
timestamp: this.timestamp,
|
||||||
duration: this.duration,
|
duration: this.duration,
|
||||||
colorSpace: this.colorSpace,
|
colorSpace: this.colorSpace,
|
||||||
|
rotation: this.rotation,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user