Don't request alpha channel when loading monochrome PNG
This commit is contained in:
parent
f9dda53c61
commit
de1a454079
1 changed files with 1 additions and 1 deletions
|
|
@ -67,7 +67,7 @@ namespace psemek::gfx
|
|||
if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8)
|
||||
png_set_expand_gray_1_2_4_to_8(png);
|
||||
|
||||
if (!(color_type & PNG_COLOR_MASK_ALPHA))
|
||||
if (!(color_type & PNG_COLOR_MASK_ALPHA) && !monochrome)
|
||||
png_set_add_alpha(png, 0xff, PNG_FILLER_AFTER);
|
||||
|
||||
png_read_update_info(png, info);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue