when the DIB header is BITMAPINFOHEADER (size 40),
a bitmap file has alpha channel only if the compression method is BI_ALPHABITFIELDS (= 6).
the original code enabled alpha channel when the compression method was BI_RGB (= 0),
which made an opaque bmp image loaded as a transparent one.
@fix
Change-Id: Id175c82294c064d0d87c7f8fa9ccafcda8f84611
if (!read_int(map, fsize, position, &tmp2)) return EINA_FALSE;
//important_colors = tmp2; // number of important colors - 0 if all
if (*image_size == 0) *image_size = fsize - header->offset;
- if ((header->comp == 0) && (header->bit_count == 32)) header->hasa = 1; // GIMP seems to store it this way
+ if ((header->comp == 6) && (header->bit_count == 32)) header->hasa = 1;
break;
}
case 108: // Windows 95/NT4 + (v4)