mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[libpng16] Fixed build when using #define PNG_NO_READ_GAMMA in png_do_compose()
in pngrtran.c (Domani Hannes).
This commit is contained in:
@@ -3968,7 +3968,7 @@ png_do_compose(png_row_infop row_info, png_bytep row, png_structrp png_ptr)
|
||||
*sp = (png_byte)png_ptr->background.gray;
|
||||
|
||||
else if (a < 0xff)
|
||||
png_composite(*sp, *sp, a, png_ptr->background_1.gray);
|
||||
png_composite(*sp, *sp, a, png_ptr->background.gray);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4037,7 +4037,7 @@ png_do_compose(png_row_infop row_info, png_bytep row, png_structrp png_ptr)
|
||||
png_uint_16 g, v;
|
||||
|
||||
g = (png_uint_16)(((*sp) << 8) + *(sp + 1));
|
||||
png_composite_16(v, g, a, png_ptr->background_1.gray);
|
||||
png_composite_16(v, g, a, png_ptr->background.gray);
|
||||
*sp = (png_byte)((v >> 8) & 0xff);
|
||||
*(sp + 1) = (png_byte)(v & 0xff);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user