mediaDevices.getUserMedia provides "fake" video dimensions instead of rejecting the promise
Reported by
viktor.k...@gmail.com,
Jul 15
|
|
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:61.0) Gecko/20100101 Firefox/61.0 Steps to reproduce the problem: 1. Require an unsupported resolution (eg, 1x1 or 3x333). 2. Be surprised that this is supported. What is the expected behavior? If I request video.width.exact=1 or video.width.max=1 the promise must be rejected. See the example in 1x1.html. What went wrong? If the camera does not support the required resolution, the browser must reject the promise. However, if the requested resolution is below the maximum supported, Chrome resizes the video output to fit the constraints. Did this work before? No Does this work in other browsers? Yes Chrome version: 67.0.3396.99 Channel: stable OS Version: 6.1 (Windows 7) Flash Version: I can reproduce this bug on Chrome 67.0.3396.99 and 58.0.3029.110 under Windows 7 and Windows 10. Firefox and Edge are not affected.
,
Jul 16
BTW, nothing in the spec says that the browser must reject the promise in the examples you provide. Both downscaling and rejecting are valid behaviors according to spec.
,
Jul 17
Thank you for clarification and please forgive my confusion. For me this is an unexpected behaviour, because in fact the source doesn't support the required capability and I mistakenly believed that browser must reject the promise since 1x1 is not an operating mode. As for resizeMode, are there any plans when it will be supported by Chrome?
,
Jul 17
We plan to support resizeMode, but we do not know when it will be ready. See bug 854980 .
,
Jul 17
Thank you for your time! I already starred that bug and I'll wait for any good news, because my task requires to detect only native resolutions. Best regards, Victor. |
|
►
Sign in to add a comment |
|
Comment 1 by guidou@chromium.org
, Jul 16