GetImage.py 192 B

123456789
  1. from PIL import Image
  2. from io import BytesIO
  3. def get_vc_image(element):
  4. image = element.screenshot_as_png
  5. imageStream = BytesIO(image)
  6. im = Image.open(imageStream)
  7. return im