- From: Mathieu Hofman via GitHub <sysbot+gh@w3.org>
- Date: Sat, 03 Nov 2018 01:31:54 +0000
- To: public-webrtc-logs@w3.org
> > > I would also like to see a way to expose the source pixel ratio of the captured content. > > The current workaround for this would be: > > ```js > const [track] = (await navigator.mediaDevices.getDisplayMedia()).getVideoTracks(); > const pixelRatio = track.getCapabilities().max.height / track.getSettings().height; > > await track.applyConstraints(myConstraints); > ``` > > I'd recommend opening a new issue if you think this requires its own constraint. The use case for this is mostly when using a stream in `resizeMode == none` which means max height == current height. I guess a work around would be cloning the track and applying a resize constraint on it, but that seems insane just to read out the ratio. I'll open a separate issue to track this. -- GitHub Notification of comment by mhofman Please view or discuss this issue at https://github.com/w3c/mediacapture-screen-share/issues/35#issuecomment-435550581 using your GitHub account
Received on Saturday, 3 November 2018 01:31:55 UTC