is this faster btw? I guess big doesn't help, it's only retrieved once anyway? But is rows retrieved in every loop? the python interpreter aint too smart?
def getPixels(fileName):
im = PIL.Image.open(fileName)
colors = []
r, c = im.size
big = range(0, c)
rows = range(0, r)
for y in big:
row = []
for x in rows:
color = im.getpixel((x,y))
row.append(color)
colors.append(row)
return numpy.array(colors)
--
http://mail.python.org/mailman/listinfo/python-list
