Although you probably do want to store each pixel as an integer for faster comparison, you can't read them in that way since each pixel only takes 3 bytes (not 4 or 8).

Another problem is that each row is rounded up to the nearest multiple of 4, so there may be some bytes to skip at the end of each row. E.g., if the image is 10 pixels wide it will have 30 bytes of pixel info and then 2 extra bytes for each row.