This is an automated email from the ASF dual-hosted git repository. solomax pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/openmeetings.git
The following commit(s) were added to refs/heads/master by this push: new dab264e [OPENMEETINGS-2507] client update is improved dab264e is described below commit dab264e2dbae3d856737c32c11f12096c775c88b Author: Maxim Solodovnik <solomax...@gmail.com> AuthorDate: Wed Mar 3 22:43:57 2021 +0700 [OPENMEETINGS-2507] client update is improved --- openmeetings-web/src/main/front/room/src/video.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/openmeetings-web/src/main/front/room/src/video.js b/openmeetings-web/src/main/front/room/src/video.js index 7f4d4b5..fb146d9 100644 --- a/openmeetings-web/src/main/front/room/src/video.js +++ b/openmeetings-web/src/main/front/room/src/video.js @@ -6,7 +6,7 @@ const Volume = require('./volume'); module.exports = class Video { constructor(msg) { - const states = [], self = this; + const states = [], self = this, vidSize = {}; let sd, v, vc, t, footer, size, vol, iceServers , lm, level, userSpeaks = false, muteOthers , hasVideo, isSharing, isRecording; @@ -193,6 +193,8 @@ module.exports = class Video { }, vtracks = state.stream.getVideoTracks(); if (vtracks && vtracks.length > 0) { const vts = vtracks[0].getSettings(); + vidSize.width = vts.width; + vidSize.height = vts.height; bmsg.width = vts.width; bmsg.height = vts.height; bmsg.fps = vts.frameRate; @@ -367,8 +369,8 @@ module.exports = class Video { } function _update(_c) { const prevA = sd.activities - , prevW = sd.width - , prevH = sd.height + , prevW = vidSize.width || sd.width // try to check actual size of video first + , prevH = vidSize.height || sd.height // try to check actual size of video first , prevCam = sd.cam , prevMic = sd.mic; sd.activities = _c.activities.sort(); @@ -500,6 +502,8 @@ module.exports = class Video { data.rtcPeer = null; } function _cleanup(evt) { + delete vidSize.width; + delete vidSize.height; OmUtil.log('!!Disposing participant ' + sd.uid); let state; while(state = states.pop()) {