Learn Before
Concept
ImageGrab Class (Pillow)
The ImageGrab class allows for copying the contents of the screen or the computer's clipboard, if an image is in the clipboard. There are only two functions, ImageGrab.grab() and ImageGrab.grabcllipboard(). ImageGrab.grab() takes a snapshot of the screen when given the bounding box to snapshot, and returns and image object.
image = ImageGrab.grab(region)
ImageGrab.grabclipboard() takes the image in the system's clipboard and returns an image object.
image = ImageGrab.grabclipboard()
0
1
Updated 2021-08-24
Tags
Python Programming Language
Data Science