On Mon, 07 Jun 2010 02:31:08 -0700, Richard Thomas wrote: > You're reading those bits backwards. You want to read the most > significant bit of each byte first...
Says who? There is no universal standard for bit-order. Among bitmap image formats, XBM is LSB-first while BMP and PBM are MSB-first. OpenGL reads or writes bitmap data in either order, controlled by glPixelStorei(). Most serial communication links (e.g. RS-232, ethernet) transmit the LSB first, although there are exceptions (e.g. I2C uses MSB-first). -- http://mail.python.org/mailman/listinfo/python-list