I have the following, that is used to convert pixel data and thus should be as fast as possible:
b = numpy.ndarray (shape=(w,h,4), dtype=numpy.uint8) a = numpy.frombuffer(buf, numpy.uint8) a.shape = (w, h, 3) b[:,:,0] = a[:,:,2] b[:,:,1] = a[:,:,1] b[:,:,2] = a[:,:,0] b[:,:,3] = 255 Can anyone tell me if there is a faster way? Will making use of weave.blitz or pyrex help? Thank You. -- http://mail.python.org/mailman/listinfo/python-list