What are some of the better libraries for image generation in Python? If I were to implement a GOTCHA (for example’s sake), thereby having to manipulate an image on the pixel level, what would my options be? Ideally I would like to save resulting image as a low-resolution jpeg, but this is mere wishing, I’ll settle for any common image format.
Thank you for your attention.
The Python Imaging Library (PIL) is the de facto image manipulation library on Python. You can find it here, or through easy_install or pip if you have them.
Edit: PIL has not been updated in a while, but it has been forked and maintained under the name pillow. Just install it this way in a shell:
The
importstatements are still the same as PIL (e.g.,from PIL import image) and is backward compatible.