From 08afaa1efc5afd879f8b6db52ccf75b7aba342e4 Mon Sep 17 00:00:00 2001 From: Cristy Date: Sun, 5 May 2019 20:15:12 -0400 Subject: [PATCH] https://imagemagick.org/discourse-server/viewtopic.php?f=3&t=35934 --- MagickCore/image.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/MagickCore/image.c b/MagickCore/image.c index a7a9c0078..169a4b1c8 100644 --- a/MagickCore/image.c +++ b/MagickCore/image.c @@ -4207,6 +4207,15 @@ MagickExport MagickBooleanType SyncImageSettings(const ImageInfo *image_info, break; } image->units=units; + option=GetImageOption(image_info,"density"); + if (option != (const char *) NULL) + { + flags=ParseGeometry(option,&geometry_info); + image->resolution.x=geometry_info.rho; + image->resolution.y=geometry_info.sigma; + if ((flags & SigmaValue) == 0) + image->resolution.y=image->resolution.x; + } } option=GetImageOption(image_info,"virtual-pixel"); if (option != (const char *) NULL) -- 2.40.0