Get pixel colors from images in Python 3

Cro prahaai at
Fri Mar 13 22:24:43 CET 2009

Good day.

As the title sais, i am trying to extract pixel colors from images, in
Python 3.

I know that for python 2.x, PIL (Python image library) can do that,
via Image > getpixel((x,y)). It returns the colors as a list with 3
parameters, Red, Green and Blue. This is exactly what i want.
Now, the problem is that PIL doesn't work in Python 3.

Can anyone suggest how to do that ?
The bigger problem is that i need to extract pixel colors for many
types of images : JPEG, PNG, BMP, GIF. For this, i might need
different codecs... I am not good at image formats and codecs.

I just want to know if i can do this in the simple way, or i have to
beg PIL to implement support for Python 3...

More information about the Python-list mailing list