On 29/04/2013 18:20, Jimmie He wrote:
I'm trying to read in the BMP data by the the code below,and I'm check the data array with WINHEX,and it is correct,but which confuse me is why the size is 0x180,but the actual picture should be 48*48 = 0x120 bytes because I use 1-bit BMP not the 24bit BMP,could any one give some hints?
[snip] What size is 0x180? If you're asking why the file size is 0x180 and not 0x120, it's simply because of the header. An image file contains not just the pixels of the image, but also information about the image. -- http://mail.python.org/mailman/listinfo/python-list