mirror of
https://github.com/open-webui/open-webui.git
synced 2025-04-02 08:59:16 +02:00
refac: audio input
This commit is contained in:
parent
fab82b51de
commit
43964de675
@ -217,7 +217,13 @@
|
||||
const startRecording = async () => {
|
||||
if ($showCallOverlay) {
|
||||
if (!audioStream) {
|
||||
audioStream = await navigator.mediaDevices.getUserMedia({ audio: true });
|
||||
audioStream = await navigator.mediaDevices.getUserMedia({
|
||||
audio: {
|
||||
echoCancellation: true,
|
||||
noiseSuppression: true,
|
||||
autoGainControl: true
|
||||
}
|
||||
});
|
||||
}
|
||||
mediaRecorder = new MediaRecorder(audioStream);
|
||||
|
||||
|
@ -161,7 +161,13 @@
|
||||
const startRecording = async () => {
|
||||
startDurationCounter();
|
||||
|
||||
stream = await navigator.mediaDevices.getUserMedia({ audio: true });
|
||||
stream = await navigator.mediaDevices.getUserMedia({
|
||||
audio: {
|
||||
echoCancellation: true,
|
||||
noiseSuppression: true,
|
||||
autoGainControl: true
|
||||
}
|
||||
});
|
||||
mediaRecorder = new MediaRecorder(stream);
|
||||
mediaRecorder.onstart = () => {
|
||||
console.log('Recording started');
|
||||
|
Loading…
x
Reference in New Issue
Block a user