Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #44514
| Date | 2013-04-29 19:10 +0100 |
|---|---|
| From | MRAB <python@mrabarnett.plus.com> |
| Subject | Re: Can read in the BMP data correctly ,but the size is not right? |
| References | <aee818ca-e077-4e52-be55-7b8282684ba4@googlegroups.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.1160.1367259060.3114.python-list@python.org> (permalink) |
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.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Can read in the BMP data correctly ,but the size is not right? Jimmie He <jimmie.he@gmail.com> - 2013-04-29 10:20 -0700
Re: Can read in the BMP data correctly ,but the size is not right? Chris Angelico <rosuav@gmail.com> - 2013-04-30 03:53 +1000
Re: Can read in the BMP data correctly ,but the size is not right? Peter Otten <__peter__@web.de> - 2013-04-29 19:57 +0200
Re: Can read in the BMP data correctly ,but the size is not right? Jimmie He <jimmie.he@gmail.com> - 2013-04-30 06:09 -0700
Re: Can read in the BMP data correctly ,but the size is not right? Jimmie He <jimmie.he@gmail.com> - 2013-05-04 03:26 -0700
Re: Can read in the BMP data correctly ,but the size is not right? MRAB <python@mrabarnett.plus.com> - 2013-04-29 19:10 +0100
Re: Can read in the BMP data correctly ,but the size is not right? 88888 Dihedral <dihedral88888@googlemail.com> - 2013-04-29 11:12 -0700
csiph-web