From: dirk Date: Fri, 15 May 2015 12:09:29 +0000 (+0000) Subject: Added extra overloads for the splice method of Magick++. X-Git-Tag: 7.0.1-0~1034 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3b8649e1b0d73b281f3f4d3a005cc3c91960e1bc;p=imagemagick Added extra overloads for the splice method of Magick++. --- diff --git a/Magick++/lib/Image.cpp b/Magick++/lib/Image.cpp index 2a79b8b90..37db1fed0 100644 --- a/Magick++/lib/Image.cpp +++ b/Magick++/lib/Image.cpp @@ -4329,6 +4329,21 @@ void Magick::Image::splice(const Geometry &geometry_) ThrowImageException; } +void Magick::Image::splice(const Geometry &geometry_, + const Color &backgroundColor_) +{ + backgroundColor(backgroundColor_); + splice(geometry_); +} + +void Magick::Image::splice(const Geometry &geometry_, + const Color &backgroundColor_,const GravityType gravity_) +{ + backgroundColor(backgroundColor_); + image()->gravity=gravity_; + splice(geometry_); +} + void Magick::Image::spread(const size_t amount_) { MagickCore::Image diff --git a/Magick++/lib/Magick++/Image.h b/Magick++/lib/Magick++/Image.h index e4ca81943..772f148c7 100644 --- a/Magick++/lib/Magick++/Image.h +++ b/Magick++/lib/Magick++/Image.h @@ -1307,6 +1307,9 @@ namespace Magick // Splice the background color into the image. void splice(const Geometry &geometry_); + void splice(const Geometry &geometry_,const Color &backgroundColor_); + void splice(const Geometry &geometry_,const Color &backgroundColor_, + const GravityType gravity_); // Spread pixels randomly within image by specified ammount void spread(const size_t amount_=3);