mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[libpng16] Reverted addition of png_set_filler_16 and png_set_add_alpha_16()
functions. They unnecessarily duplicate png_set_filler() and png_set_add_alpha() which now work properly with 16-bit images.
This commit is contained in:
@@ -522,7 +522,7 @@ void read_png(FILE *fp, int sig_read) /* File is already open */
|
||||
png_set_swap(png_ptr);
|
||||
|
||||
/* Add filler (or alpha) byte (before/after each RGB triplet) */
|
||||
png_set_filler_16(png_ptr, 0xffff, PNG_FILLER_AFTER);
|
||||
png_set_filler(png_ptr, 0xffff, PNG_FILLER_AFTER);
|
||||
|
||||
#ifdef PNG_READ_INTERLACING_SUPPORTED
|
||||
/* Turn on interlace handling. REQUIRED if you are not using
|
||||
@@ -958,7 +958,7 @@ void write_png(char *file_name /* , ... other image information ... */)
|
||||
/* Get rid of filler (OR ALPHA) bytes, pack XRGB/RGBX/ARGB/RGBA into
|
||||
* RGB (4 channels -> 3 channels). The second parameter is not used.
|
||||
*/
|
||||
png_set_filler_16(png_ptr, 0, PNG_FILLER_BEFORE);
|
||||
png_set_filler(png_ptr, 0, PNG_FILLER_BEFORE);
|
||||
|
||||
/* Flip BGR pixels to RGB */
|
||||
png_set_bgr(png_ptr);
|
||||
|
||||
Reference in New Issue
Block a user