I set up a VirtualBox to use two monitors. I tried taking a screenshot of a window on the second monitor:
import ImageGrab
im = ImageGrab.grab(windowrect)
im.save("img.png")
windowrect
I verified to be the correct rect of the window, in this case, (1616, 2, 2594, 732)
. However, img.png
is just a big black box. Any ideas how to fix this interaction between screen grabbing and VirtualBox so that I can take screenshots of the 2nd virtual monitor?