mirror of
https://github.com/arcodange-org/mediabunny.git
synced 2026-09-27 19:03:46 +02:00
Merge main into release for tag v1.14.1
This commit is contained in:
+5
-4
@@ -24,7 +24,7 @@
|
||||
chunked: true,
|
||||
chunkSize: 2**20
|
||||
});
|
||||
const outputFormat = new Mediabunny.WavOutputFormat({});
|
||||
const outputFormat = new Mediabunny.Mp4OutputFormat({});
|
||||
|
||||
const button = document.createElement('button');
|
||||
button.textContent = 'Cancel';
|
||||
@@ -47,7 +47,7 @@
|
||||
format: outputFormat,
|
||||
target
|
||||
});
|
||||
output.setMetadata({
|
||||
output.setMetadataTags({
|
||||
title: 'Bigggy',
|
||||
artist: 'Buck Bunny',
|
||||
images: [{
|
||||
@@ -105,7 +105,8 @@
|
||||
},
|
||||
*/
|
||||
video: () => ({
|
||||
discard: true,
|
||||
//discard: true,
|
||||
forceTranscode: true,
|
||||
//codec: 'avc',
|
||||
//fit: 'contain',
|
||||
//frameRate: 27.123,
|
||||
@@ -128,7 +129,7 @@
|
||||
//height: 100,
|
||||
}),
|
||||
trim: {
|
||||
start: 0,
|
||||
start: 1,
|
||||
end: 10
|
||||
},
|
||||
});
|
||||
|
||||
+14
-4
@@ -14,12 +14,22 @@
|
||||
source: new Mediabunny.BlobSource(file),
|
||||
});
|
||||
|
||||
const audioTrack = await input.getPrimaryAudioTrack();
|
||||
const sink = new Mediabunny.EncodedPacketSink(audioTrack);
|
||||
const videoTrack = await input.getPrimaryVideoTrack();
|
||||
const sink = new Mediabunny.VideoSampleSink(videoTrack);
|
||||
|
||||
console.log(await audioTrack.getDecoderConfig())
|
||||
console.log(await sink.getFirstPacket());
|
||||
console.log(await sink.getSample(await videoTrack.getFirstTimestamp()))
|
||||
|
||||
/*
|
||||
for await (const sample of sink.samples(0.99)) {
|
||||
console.log(sample);
|
||||
|
||||
if (sample.timestamp >= 2) {
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
//console.log(await sink.getSample(1))
|
||||
|
||||
/*
|
||||
const screenStream = await navigator.mediaDevices.getDisplayMedia({ video: true });
|
||||
|
||||
Generated
+6
-6
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "mediabunny",
|
||||
"version": "1.14.0",
|
||||
"version": "1.14.1",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "mediabunny",
|
||||
"version": "1.14.0",
|
||||
"version": "1.14.1",
|
||||
"license": "MPL-2.0",
|
||||
"workspaces": [
|
||||
"packages/*"
|
||||
@@ -7749,9 +7749,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/mediabunny": {
|
||||
"version": "1.13.3",
|
||||
"resolved": "https://registry.npmjs.org/mediabunny/-/mediabunny-1.13.3.tgz",
|
||||
"integrity": "sha512-kV12CVwMdhMQILGrVcyDWOgnZHwAytStQYKZeEaUj32XamYhlDX0Od4SkXVr0Yms8iapJsiCoEQdSK4UKUfooA==",
|
||||
"version": "1.14.0",
|
||||
"resolved": "https://registry.npmjs.org/mediabunny/-/mediabunny-1.14.0.tgz",
|
||||
"integrity": "sha512-GaULQgUWpz5m4S7N6iNjpyLxqhpudjcSNGLC4Ni9A0A2vA6l5frBpxQJZM2JmqrN1B2BkArnCgyuTZv7ePw2vQ==",
|
||||
"license": "MPL-2.0",
|
||||
"peer": true,
|
||||
"workspaces": [
|
||||
@@ -12242,7 +12242,7 @@
|
||||
},
|
||||
"packages/mp3-encoder": {
|
||||
"name": "@mediabunny/mp3-encoder",
|
||||
"version": "1.14.0",
|
||||
"version": "1.14.1",
|
||||
"license": "MPL-2.0",
|
||||
"devDependencies": {
|
||||
"@types/emscripten": "^1.40.1"
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "mediabunny",
|
||||
"author": "Vanilagy",
|
||||
"version": "1.14.0",
|
||||
"version": "1.14.1",
|
||||
"description": "Pure TypeScript media toolkit for reading, writing, and converting media files, directly in the browser.",
|
||||
"type": "module",
|
||||
"workspaces": [
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "@mediabunny/mp3-encoder",
|
||||
"author": "Vanilagy",
|
||||
"version": "1.14.0",
|
||||
"version": "1.14.1",
|
||||
"description": "MP3 encoder extension for Mediabunny, based on LAME.",
|
||||
"main": "./dist/bundles/mediabunny-mp3-encoder.mjs",
|
||||
"module": "./dist/bundles/mediabunny-mp3-encoder.mjs",
|
||||
|
||||
+1
-1
@@ -723,7 +723,7 @@ export class Conversion {
|
||||
await tempOutput.start();
|
||||
|
||||
const sink = new VideoSampleSink(track);
|
||||
const firstSample = await sink.getSample(this._startTimestamp);
|
||||
const firstSample = await sink.getSample(firstTimestamp); // Let's just use the first sample
|
||||
|
||||
if (firstSample) {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user