mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[master] Imported from libpng-1.4.1beta07.tar
This commit is contained in:
@@ -436,7 +436,8 @@ png_write_IHDR(png_structp png_ptr, png_uint_32 width, png_uint_32 height,
|
||||
case 4:
|
||||
case 8:
|
||||
case 16: png_ptr->channels = 1; break;
|
||||
default: png_error(png_ptr, "Invalid bit depth for grayscale image");
|
||||
default: png_error(png_ptr,
|
||||
"Invalid bit depth for grayscale image");
|
||||
}
|
||||
break;
|
||||
case PNG_COLOR_TYPE_RGB:
|
||||
@@ -639,7 +640,9 @@ png_write_PLTE(png_structp png_ptr, png_colorp palette, png_uint_32 num_pal)
|
||||
png_write_chunk_data(png_ptr, buf, (png_size_t)3);
|
||||
}
|
||||
#else
|
||||
/* This is a little slower but some buggy compilers need to do this instead */
|
||||
/* This is a little slower but some buggy compilers need to do this
|
||||
* instead
|
||||
*/
|
||||
pal_ptr=palette;
|
||||
for (i = 0; i < num_pal; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user