Make media player AudioContext match audio track sample rate

This commit is contained in:
Vanilagy
2025-05-30 20:12:00 +02:00
parent 218803a9fe
commit 176d21cf50
2 changed files with 21 additions and 19 deletions
+4 -3
View File
@@ -21,7 +21,7 @@
chunked: true,
chunkSize: 2**20
});
const outputFormat = new Metamuxer.Mp4OutputFormat();
const outputFormat = new Metamuxer.WavOutputFormat();
const button = document.createElement('button');
button.textContent = 'Cancel';
@@ -38,8 +38,8 @@
target
}),
audio: {
numberOfChannels: 2,
//sampleRate: 8000
numberOfChannels: 1,
sampleRate: 4000
//discard: true
//forceReencode: true,
},
@@ -68,6 +68,7 @@
},
*/
video: {
discard: true,
width: 1280,
//discard: true,
//width: 640