]> granicus.if.org Git - imagemagick/commitdiff
Add support for image.extent
authorCristy <urban-warrior@imagemagick.org>
Sat, 7 Jul 2018 16:03:24 +0000 (12:03 -0400)
committerCristy <urban-warrior@imagemagick.org>
Sat, 7 Jul 2018 16:03:24 +0000 (12:03 -0400)
MagickCore/fx.c

index 6aa38f771dd669aa8ad8fcfe2cb3e4d9d90bd350..8a5990a55246ef23cc633593a1ff2da5deaf0326 100644 (file)
@@ -1661,6 +1661,13 @@ static double FxGetSymbol(FxInfo *fx_info,const PixelChannel channel,
           (LocaleCompare(symbol,"image.skewness") == 0) ||
           (LocaleCompare(symbol,"image.standard_deviation") == 0))
         return(FxChannelStatistics(fx_info,image,channel,symbol+6,exception));
+      if (LocaleCompare(symbol,"image.extent") == 0)
+        {
+          if (image->extent != 0)
+            return(image->extent);
+          else
+            return(GetBlobSize(fx_info->images));
+        }
       if (LocaleCompare(symbol,"image.resolution.x") == 0)
         return(image->resolution.x);
       if (LocaleCompare(symbol,"image.resolution.y") == 0)