#if defined(PNG_sRGB_SUPPORTED)
if (png_get_valid(ping,ping_info,PNG_INFO_sRGB))
{
- (void) FormatMagickString(msg,MaxTextExtent,"intent=%d (See Rendering intent)",
+ (void) FormatMagickString(msg,MaxTextExtent,
+ "intent=%d (See Rendering intent)",
(int) intent);
(void) SetImageProperty(image,"PNG:sRGB ",msg);
}
if (png_get_valid(ping,ping_info,PNG_INFO_gAMA))
{
- (void) FormatMagickString(msg,MaxTextExtent,"gamma=%.8g (See Gamma, above)",
+ (void) FormatMagickString(msg,MaxTextExtent,
+ "gamma=%.8g (See Gamma, above)",
file_gamma);
(void) SetImageProperty(image,"PNG:gAMA ",msg);
}
#if defined(PNG_pHYs_SUPPORTED)
if (png_get_valid(ping,ping_info,PNG_INFO_pHYs))
{
- (void) FormatMagickString(msg,MaxTextExtent,"x_res=%.10g, y_res=%.10g, units=%d",
+ (void) FormatMagickString(msg,MaxTextExtent,
+ "x_res=%.10g, y_res=%.10g, units=%d",
(double) x_resolution,(double) y_resolution, unit_type);
(void) SetImageProperty(image,"PNG:pHYs ",msg);
}
}
#endif
- /* TO DO: vpAg */
+ if ((image->page.width != 0 && image->page.width != image->columns) ||
+ (image->page.height != 0 && image->page.height != image->rows))
+ {
+ (void) FormatMagickString(msg,MaxTextExtent,
+ "width=%.20g, height=%.20g",
+ (double) image->page.width,(double) image->page.height);
+ (void) SetImageProperty(image,"PNG:vpAg ",msg);
+ }
}
/*