Zoom and pan on received screen share when larger than the available space to view it #12187
Labels
1. to develop
design
enhancement
feature: call 📹
Voice and video calls
feature: frontend 🖌️
"Web UI" client
Milestone
How to use GitHub
Is your feature request related to a problem? Please describe.
When another participant shares a screen which is noticeably larger than your own screen (or the size of the browser window if not maximized) the text in the received screen share may not be readable. For example, if another participant shares a 4K screen (3840x2160) and you only have a Full HD screen (1920x1080). This could be even worse if the shared screen has a vertical orientation and your screen has an horizontal orientation, as the 3840 pixels would need to fit in 1080 pixels (actually less, as the window decorations, browser menu, Nextcloud header and so on take some extra pixels).
Describe the solution you'd like
When a received screen share is noticeably larger than the available space to view it it should be possible to zoom on the screen share to show it at 100% resolution and then move the focused area as needed (the same as using an image viewer with 100% zoom and a large image). It should not start zoomed in, though; the starting state should be that the screen share fits the available space (just like done now) and then the user zooms in if needed/desired.
Additional context
In order to implement this there is no need to use
getSettings
,getConstraints
nor anything similar on the receivedMediaTrack
(and, in fact, those methods may not provide any useful information with remote tracks).video
elements provide the attributesvideoWidth
andvideoHeight
with the intrinsic size of the video, so that should be enough to check if the video is larger than thevideo
element that shows it and how much the element would need to be resized to zoom in.Note that the size of the video can dynamically change, for example, if a window is being shared and that window is resized.
The text was updated successfully, but these errors were encountered: