Taking a screenshot with DesktopCapturer

40 views
Skip to first unread message

g...@chromium.org

unread,
Nov 11, 2017, 12:10:57 PM11/11/17
to discuss-webrtc
Hi folks. I find that my use of DesktopCapturer to grab a screenshot sometimes returns only a portion of the screen. It's possible that I'm getting data from the frame and encoding it into a JPG improperly, bu it's also entirely possible that I'm holding the DesktopCapturer itself wrong. The odd thing is that it works perfectly on my local machine -- it's only on some Chromium bots (where I really need it to work) that it returns a partial screen. Could someone who knows how this stuff work take a look at this CaptureScreen() implementation and the use of PNGCodec::EncodeBGRASkBitmap down here and let me know if there's something obviously wrong with it?

Many thanks.

Greg

anil2...@gmail.com

unread,
Nov 12, 2017, 2:11:58 AM11/12/17
to discuss-webrtc
I hv seen DesktopCapturer does not intialized with exact resolution of screen on some machine.
that might be the reason of partial screen in your case as it might have been initialized with less width and height of the machine resolution.

g...@chromium.org

unread,
Apr 16, 2018, 7:32:40 AM4/16/18
to discuss-webrtc
Thanks. How can I tell if that's happening, and how can I fix it?

In the latest snapshots I've looked at, the resulting image is all black. This is not so helpful. :-(

Reply all
Reply to author
Forward
0 new messages