From d06cca34d4616cb3a049b6e106a77fc9a0709ba1 Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Sat, 30 Jan 2021 20:23:55 +0100 Subject: [PATCH] Enforce constraints --- assets/js/components/calls/window.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/assets/js/components/calls/window.js b/assets/js/components/calls/window.js index 536105be..6a1b8b31 100644 --- a/assets/js/components/calls/window.js +++ b/assets/js/components/calls/window.js @@ -739,7 +739,7 @@ class CallWindow extends CustomEvents { * @param {MediaStream} stream Target stream */ async applyStream(peerID, muted, stream) { - + // Remove any previous video stream if(this.videoEls.has(peerID)) { this.removeVideoElement(peerID) @@ -956,8 +956,8 @@ class CallWindow extends CustomEvents { const videoTrack = this.mainStream.getVideoTracks()[0]; // Fix video & canvas size - videoTarget.width = videoTrack.getSettings().width - videoTarget.height = videoTrack.getSettings().height + videoTarget.width = 320; + videoTarget.height = 240; canvasTarget.width = videoTarget.width; canvasTarget.height = videoTarget.height;