]> granicus.if.org Git - imagemagick/commitdiff
Added masklightColor to Image and fixed highlightColor and lowlightColor.
authorDirk Lemstra <dirk@git.imagemagick.org>
Fri, 10 Nov 2017 12:07:49 +0000 (13:07 +0100)
committerDirk Lemstra <dirk@git.imagemagick.org>
Fri, 10 Nov 2017 12:07:49 +0000 (13:07 +0100)
Magick++/lib/Image.cpp
Magick++/lib/Magick++/Image.h

index 426a02263f62660769b85dd5104a0fa171d97639..f4fc34a689454bf5ddb59a8a10088cae05527205 100644 (file)
@@ -998,7 +998,7 @@ void Magick::Image::highlightColor(const Color color_)
     value;
 
   value=color_;
-  artifact("highlight-color",value);
+  artifact("compare:highlight-color",value);
 }
 
 void Magick::Image::iccColorProfile(const Magick::Blob &colorProfile_)
@@ -1133,7 +1133,7 @@ void Magick::Image::lowlightColor(const Color color_)
     value;
 
   value=color_;
-  artifact("lowlight-color",value);
+  artifact("compare:lowlight-color",value);
 }
 
 void Magick::Image::magick(const std::string &magick_)
@@ -1162,6 +1162,15 @@ std::string Magick::Image::magick(void) const
   return(constOptions()->magick());
 }
 
+void Magick::Image::masklightColor(const Color color_)
+{
+  std::string
+    value;
+
+  value=color_;
+  artifact("compare:masklight-color",value);
+}
+
 double Magick::Image::meanErrorPerPixel(void) const
 {
   return(constImage()->error.mean_error_per_pixel);
index 3ca9712025e6a50195ff0d01b8a95bebbe86e504..c20753862a3cc29ea721e066d3cfa3761d5528ad 100644 (file)
@@ -327,6 +327,9 @@ namespace Magick
     void magick(const std::string &magick_);
     std::string magick(void) const;
 
+    // When comparing images, mask pixel differences with this color.
+    void masklightColor(const Color color_);
+
     // The mean error per pixel computed when an image is color reduced
     double meanErrorPerPixel(void) const;