From cd27b136e4e1bcbb1a4d04a7da56be10f13bc906 Mon Sep 17 00:00:00 2001 From: Miroslav Pejic Date: Sun, 23 Jan 2022 16:37:08 +0100 Subject: [PATCH] [mirotalksfu] - fix snapshot video width-height --- public/js/RoomClient.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/js/RoomClient.js b/public/js/RoomClient.js index 766ec63..ec3c3e2 100644 --- a/public/js/RoomClient.js +++ b/public/js/RoomClient.js @@ -1494,8 +1494,8 @@ class RoomClient { btnTs.addEventListener('click', () => { this.sound('snapshot'); let context, canvas, width, height, dataURL; - width = videoPlayer.offsetWidth; - height = videoPlayer.offsetHeight; + width = videoPlayer.videoWidth; + height = videoPlayer.videoHeight; canvas = canvas || document.createElement('canvas'); canvas.width = width; canvas.height = height;