diff --git a/Frontend/Electron/package.json b/Frontend/Electron/package.json index 5bf9d1d..5253535 100644 --- a/Frontend/Electron/package.json +++ b/Frontend/Electron/package.json @@ -1,7 +1,7 @@ { "name": "discord", "private": true, - "version": "1.0.4", + "version": "1.0.5", "description": "A Discord clone built with Convex, React, and Electron", "author": "Moyettes", "type": "module", diff --git a/Frontend/Electron/src/contexts/VoiceContext.jsx b/Frontend/Electron/src/contexts/VoiceContext.jsx index 5188eea..acb01e2 100644 --- a/Frontend/Electron/src/contexts/VoiceContext.jsx +++ b/Frontend/Electron/src/contexts/VoiceContext.jsx @@ -78,7 +78,23 @@ export const VoiceProvider = ({ children }) => { setToken(lkToken); - const newRoom = new Room({ adaptiveStream: false, dynacast: false, autoSubscribe: true }); + const newRoom = new Room({ + adaptiveStream: false, + dynacast: false, + autoSubscribe: true, + audioCaptureDefaults: { + autoGainControl: true, + echoCancellation: true, + noiseSuppression: true, + channelCount: 2, + sampleRate: 48000, + }, + publishDefaults: { + audioPreset: { maxBitrate: 384_000 }, + dtx: true, + red: true, + }, + }); await newRoom.connect(import.meta.env.VITE_LIVEKIT_URL, lkToken); await newRoom.localParticipant.setMicrophoneEnabled(!isMuted && !isDeafened);