1 2 3 4 5<!DOCTYPE html> 6<html lang="en"> 7<head> 8 <meta charset="utf-8" /> 9 <meta name="viewport" content="width=device-width,minimum-scale=1,initial-scale=1,shrink-to-fit=no" /> 10 <title>Magick++, C++ API for ImageMagick: Image Class @ ImageMagick</title> 11 <meta name="application-name" content="ImageMagick" /> 12 <meta name="description" content="Use ImageMagick® to create, edit, compose, or convert bitmap images. You can resize your image, crop it, change its shades and colors, add captions, among other operations." /> 13 <meta name="application-url" content="https://imagemagick.org" /> 14 <meta name="generator" content="PHP" /> 15 <meta name="keywords" content="magick++, c++, api, for, imagemagick:, image, class, ImageMagick, PerlMagick, image processing, image, photo, software, Magick++, OpenMP, convert" /> 16 <meta name="rating" content="GENERAL" /> 17 <meta name="robots" content="INDEX, FOLLOW" /> 18 <meta name="generator" content="ImageMagick Studio LLC" /> 19 <meta name="author" content="ImageMagick Studio LLC" /> 20 <meta name="revisit-after" content="2 DAYS" /> 21 <meta name="resource-type" content="document" /> 22 <meta name="copyright" content="Copyright (c) 1999-2017 ImageMagick Studio LLC" /> 23 <meta name="distribution" content="Global" /> 24 <meta name="magick-serial" content="P131-S030410-R485315270133-P82224-A6668-G1245-1" /> 25 <meta name="google-site-verification" content="_bMOCDpkx9ZAzBwb2kF3PRHbfUUdFj2uO8Jd1AXArz4" /> 26 <link href="Image++.html" rel="canonical" /> 27 <link href="../../images/wand.png" rel="icon" /> 28 <link href="../../images/wand.ico" rel="shortcut icon" /> 29 <link href="../assets/magick.css" rel="stylesheet" /> 30</head> 31<body> 32 <header> 33 <nav class="navbar navbar-expand-md navbar-dark fixed-top bg-dark"> 34 <a class="navbar-brand" href="../../"><img class="d-block" id="icon" alt="ImageMagick" width="32" height="32" src="../../images/wand.ico"/></a> 35 <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarsMagick" aria-controls="navbarsMagick" aria-expanded="false" aria-label="Toggle navigation"> 36 <span class="navbar-toggler-icon"></span> 37 </button> 38 39 <div class="navbar-collapse collapse" id="navbarsMagick" style=""> 40 <ul class="navbar-nav mr-auto"> 41 <li class="nav-item "> 42 <a class="nav-link" href="quantize.html">Home <span class="sr-only">(current)</span></a> 43 </li> 44 <li class="nav-item "> 45 <a class="nav-link" href="../../www/download.html">Download</a> 46 </li> 47 <li class="nav-item "> 48 <a class="nav-link" href="../../www/command-line-tools.html">Tools</a> 49 </li> 50 <li class="nav-item "> 51 <a class="nav-link" href="../../www/command-line-processing.html">Command-line</a> 52 </li> 53 <li class="nav-item "> 54 <a class="nav-link" href="../../www/resources.html">Resources</a> 55 </li> 56 <li class="nav-item "> 57 <a class="nav-link" href="../../www/develop.html">Develop</a> 58 </li> 59 <li class="nav-item"> 60 <a class="nav-link" target="_blank" href="https://imagemagick.org/discourse-server/">Community</a> 61 </li> 62 </ul> 63 <form class="form-inline my-2 my-lg-0" action="https://imagemagick.org/script/search.php"> 64 <input class="form-control mr-sm-2" type="text" name="q" placeholder="Search" aria-label="Search"> 65 <button class="btn btn-outline-success my-2 my-sm-0" type="submit" name="sa">Search</button> 66 </form> 67 </div> 68 </nav> 69 <div class="container"> 70 <script async="async" src="https://localhost/pagead/js/adsbygoogle.js"></script> <ins class="adsbygoogle" 71 style="display:block" 72 data-ad-client="ca-pub-3129977114552745" 73 data-ad-slot="6345125851" 74 data-ad-format="auto"></ins> 75 <script> 76 (adsbygoogle = window.adsbygoogle || []).push({}); 77 </script> 78 79 </div> 80 </header> 81 <main class="container"> 82 <div class="magick-template"> 83<h1> Magick::Image Class</h1> 84<p class="navigation-index">[<a href="Image++.html#BLOBs">BLOBs</a> • <a href="Image++.html#Constructors">Constructors</a> • <a href="Image++.html#Image%20Manipulation%20Methods">Image Manipulation Methods</a> • <a href="Image++.html#Image%20Attributes">Image Attributes</a> • <a href="Image++.html#Raw%20Image%20Pixel%20Access">Low-Level Image Pixel Access</a>]</p> 85<div class="doc-section"> 86<p>Image is the primary object in Magick++ and represents 87a single image frame (see <a href="http://www.imagemagick.org/Magick++/ImageDesign.html">design</a> ). The 88<a href="http://www.imagemagick.org/Magick++/STL.html">STL interface</a> <b>must</b> be used to operate on 89image sequences or images (e.g. of format GIF, TIFF, MIFF, Postscript, 90& MNG) which are comprised of multiple image frames. Individual 91frames of a multi-frame image may be requested by adding array-style 92notation to the end of the file name (e.g. "animation.gif[3]" retrieves 93the fourth frame of a GIF animation. Various image manipulation 94operations may be applied to the image. Attributes may be set on the 95image to influence the operation of the manipulation operations. The <a 96 href="http://www.imagemagick.org/Magick++/Pixels.html"> Pixels</a> class provides low-level access to 97image 98pixels. As a convenience, including <tt><font color="#663366"><Magick++.h></font></tt> 99is sufficient in order to use the complete Magick++ API. The Magick++ 100API is enclosed within the <i>Magick</i> namespace so you must either 101add the prefix "<tt> Magick::</tt> " to each class/enumeration name or 102add 103the statement "<tt> using namespace Magick;</tt>" after including the <tt>Magick++.h</tt> 104header.</p> 105<p>The preferred way to allocate Image objects is via automatic 106allocation (on the stack). There is no concern that allocating Image 107objects on the stack will excessively enlarge the stack since Magick++ 108allocates all large data objects (such as the actual image data) from 109the heap. Use of automatic allocation is preferred over explicit 110allocation (via <i>new</i>) since it is much less error prone and 111allows use of C++ scoping rules to avoid memory leaks. Use of automatic 112allocation allows Magick++ objects to be assigned and copied just like 113the C++ intrinsic data types (e.g. '<i>int</i> '), leading to clear and 114easy to read code. Use of automatic allocation leads to naturally 115exception-safe code since if an exception is thrown, the object is 116automagically deallocated once the stack unwinds past the scope of the 117allocation (not the case for objects allocated via <i>new</i> ). </p> 118<p>Image is very easy to use. For example, here is a the source to a 119program which reads an image, crops it, and writes it to a new file 120(the 121exception handling is optional but strongly recommended): </p> 122<pre class="code"> 123#include <Magick++.h> 124#include <iostream> 125using namespace std; 126using namespace Magick; 127int main(int argc,char **argv) 128{ 129 InitializeMagick(*argv); 130 131 // Construct the image object. Separating image construction from the 132 // the read operation ensures that a failure to read the image file 133 // doesn't render the image object useless. 134 Image image; 135 try { 136 // Read a file into image object 137 image.read( "girl.gif" ); 138 139 // Crop the image to specified size (width, height, xOffset, yOffset) 140 image.crop( Geometry(100,100, 100, 100) ); 141 142 // Write the image to a file 143 image.write( "x.gif" ); 144 } 145 catch( Exception &error_ ) 146 { 147 cout << "Caught exception: " << error_.what() << endl; 148 return 1; 149 } 150 return 0; 151} 152</pre> 153The following is the source to a program which illustrates the use of 154Magick++'s efficient reference-counted assignment and copy-constructor 155operations which minimize use of memory and eliminate unnecessary copy 156operations (allowing Image objects to be efficiently assigned, and 157copied into containers). The program accomplishes the 158following: 159<ol> 160 <li> Read master image.</li> 161 <li> Assign master image to second image.</li> 162 <li> Resize second image to the size 640x480.</li> 163 <li> Assign master image to a third image.</li> 164 <li> Resize third image to the size 800x600.</li> 165 <li> Write the second image to a file.</li> 166 <li> Write the third image to a file.</li> 167</ol> 168<pre class="code"> 169#include <Magick++.h> 170#include <iostream> 171using namespace std; 172using namespace Magick; 173int main(int argc,char **argv) 174{ 175 InitializeMagick(*argv); 176 177 Image master("horse.jpg"); 178 Image second = master; 179 second.resize("640x480"); 180 Image third = master; 181 third.resize("800x600"); 182 second.write("horse640x480.jpg"); 183 third.write("horse800x600.jpg"); 184 return 0; 185} 186</pre> 187During the entire operation, a maximum of three images exist in memory 188and the image data is never copied. 189<p>The following is the source for another simple program which creates 190a 100 by 100 pixel white image with a red pixel in the center and 191writes it to a file: </p> 192<pre class="code"> 193#include <Magick++.h> 194using namespace std; 195using namespace Magick; 196int main(int argc,char **argv) 197{ 198 InitializeMagick(*argv); 199 Image image( "100x100", "white" ); 200 image.pixelColor( 49, 49, "red" ); 201 image.write( "red_pixel.png" ); 202 return 0; 203} 204</pre> 205If you wanted to change the color image to grayscale, you could add the 206lines: 207<pre class="code"> 208image.quantizeColorSpace( GRAYColorspace ); 209image.quantizeColors( 256 ); 210image.quantize( ); 211</pre> 212</p> 213<p>or, more simply: </p> 214<pre class="code"> 215 image.type( GrayscaleType ); 216</pre> 217<p>prior to writing the image. </p> 218</div> 219<h2> <a name="BLOBs"></a> BLOBs</h2> 220<div class="doc-section"> 221While encoded images (e.g. JPEG) are most often written-to and 222read-from a disk file, encoded images may also reside in memory. 223Encoded 224images in memory are known as BLOBs (Binary Large OBjects) and may be 225represented using the <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> class. The encoded 226image may be initially placed in memory by reading it directly from a 227file, reading the image from a database, memory-mapped from a disk 228file, or could be written to memory by Magick++. Once the encoded image 229has been placed within a Blob, it may be read into a Magick++ Image via 230a <a href="Image++.html#constructor_blob">constructor</a> or <a href="Image++.html#read">read()</a> 231. Likewise, a Magick++ image may be written to a Blob via <a 232 href="Image++.html#write"> write()</a> . 233<p>An example of using Image to write to a Blob follows: <br> 234 </p> 235<pre class="code"> 236#include <Magick++.h> 237using namespace std; 238using namespace Magick; 239int main(int argc,char **argv) 240{ 241 InitializeMagick(*argv); 242 243 // Read GIF file from disk 244 Image image( "giraffe.gif" ); 245 // Write to BLOB in JPEG format 246 Blob blob; 247 image.magick( "JPEG" ) // Set JPEG output format 248 image.write( &blob ); 249 250 [ Use BLOB data (in JPEG format) here ] 251 252 return 0; 253} 254</pre> 255<p><br> 256likewise, to read an image from a Blob, you could use one of the 257following examples: </p> 258<p>[ <font color="#000000">Entry condition for the following examples 259is that <i>data</i> is pointer to encoded image data and <i>length</i> 260represents the size of the data</font> ] </p> 261<pre class="code"> 262Blob blob( data, length ); 263Image image( blob ); 264</pre> 265or 266<pre class="code"> 267Blob blob( data, length ); 268Image image; 269image.read( blob); 270</pre> 271some images do not contain their size or format so the size and format must be specified in advance: 272<pre class="code"> 273Blob blob( data, length ); 274Image image; 275image.size( "640x480") 276image.magick( "RGBA" ); 277image.read( blob); 278</pre> 279</div> 280<h2> <a name="Constructors"></a> Constructors</h2> 281<div class="doc-section"> 282Image may be constructed in a number of ways. It may be constructed 283from a file, a URL, or an encoded image (e.g. JPEG) contained in an 284in-memory <a href="http://www.imagemagick.org/Magick++/Blob.html"> BLOB</a> . The available Image 285constructors are shown in the following table: <br> 286 <br> 287 288<ul><table bgcolor="#ffffff" border="1" width="100%"> 289 <caption><b>Image Constructors</b></caption> <tbody> 290 <tr> 291 <td> 292 <center><b>Signature</b></center> 293 </td> 294 <td> 295 <center><b>Description</b></center> 296 </td> 297 </tr> 298 <tr> 299 <td><font size="-1">const std::string &imageSpec_</font></td> 300 <td><font size="-1">Construct Image by reading from file or URL 301specified by <i>imageSpec_</i>. Use array notation (e.g. filename[9]) 302to select a specific scene from a multi-frame image.</font></td> 303 </tr> 304 <tr> 305 <td><font size="-1">const Geometry &size_, const <a 306 href="http://www.imagemagick.org/Magick++/Color.html"> Color</a> &color_</font></td> 307 <td><font size="-1">Construct a blank image canvas of specified 308size and color</font></td> 309 </tr> 310 <tr> 311 <td><a name="constructor_blob"></a> <font size="-1">const <a 312 href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> &blob_</font></td> 313 <td rowspan="5"><font size="-1">Construct Image by reading from 314encoded image data contained in an in-memory <a href="http://www.imagemagick.org/Magick++/Blob.html">BLOB</a> 315. Depending on the constructor arguments, the Blob <a href="Image++.html#size">size</a> 316, <a href="Image++.html#depth">depth</a> , <a href="Image++.html#magick">magick</a> (format) 317may 318also be specified. Some image formats require that size be specified. 319The default ImageMagick uses for depth depends on the compiled-in 320Quantum size (8 or 16). If ImageMagick's Quantum size does not 321match that of the image, the depth may need to be specified. 322ImageMagick can usually automagically detect the image's format. 323When a format can't be automagically detected, the format (<a 324 href="Image++.html#magick">magick</a> ) must be specified.</font></td> 325 </tr> 326 <tr> 327 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 328&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size_</font></td> 329 </tr> 330 <tr> 331 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 332&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size, 333size_t depth</font></td> 334 </tr> 335 <tr> 336 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 337&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size, 338size_t depth_, const string &magick_</font></td> 339 </tr> 340 <tr> 341 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 342&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size, 343const 344string &magick_</font></td> 345 </tr> 346 <tr> 347 <td><font size="-1">const size_t width_, </font> <br> 348 <font size="-1">const size_t height_,</font> <br> 349 <font size="-1">std::string map_,</font> <br> 350 <font size="-1">const <a href="http://www.imagemagick.org/Magick++/Enumerations.html#StorageType"> 351StorageType</a> type_,</font> <br> 352 <font size="-1">const void *pixels_</font></td> 353 <td><font size="-1">Construct a new Image based on an array of 354image pixels. The pixel data must be in scanline order top-to-bottom. 355The data can be character, short int, integer, float, or double. Float 356and double require the pixels to be normalized [0..1]. The other types 357are [0..MaxRGB]. For example, to create a 640x480 image from 358unsigned red-green-blue character data, use</font> 359 <p><font size="-1"> Image image( 640, 480, "RGB", 3600, pixels );</font> </p> 361 <p><font size="-1">The parameters are as follows:</font> <br> 362 363 <table border="0" width="100%"> 364 <tbody> 365 <tr> 366 <td><font size="-1">width_</font></td> 367 <td><font size="-1">Width in pixels of the image.</font></td> 368 </tr> 369 <tr> 370 <td><font size="-1">height_</font></td> 371 <td><font size="-1">Height in pixels of the image.</font></td> 372 </tr> 373 <tr> 374 <td><font size="-1">map_</font></td> 375 <td><font size="-1">This character string can be any 376combination or order of R = red, G = green, B = blue, A = alpha, C = 377cyan, Y = yellow M = magenta, and K = black. The ordering reflects the 378order of the pixels in the supplied pixel array.</font></td> 379 </tr> 380 <tr> 381 <td><font size="-1">type_</font></td> 382 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#StorageType">Pixel 383storage type</a> (CharPixel, ShortPixel, IntegerPixel, FloatPixel, or 384DoublePixel)</font></td> 385 </tr> 386 <tr> 387 <td><font size="-1">pixels_</font></td> 388 <td><font size="-1">This array of values contain the pixel 389components as defined by the map_ and type_ parameters. The length of 390the arrays must equal the area specified by the width_ and height_ 391values and type_ parameters.</font></td> 392 </tr> 393 </tbody> 394 </table> 395 </p> 396 </td> 397 </tr> 398 </tbody> 399</table></ul> 400</div> 401<h2> <a name="Image Manipulation Methods"></a> Image Manipulation Methods</h2> 402<div class="doc-section"> 403<i>Image</i> supports access to all the single-image (versus 404image-list) manipulation operations provided by the ImageMagick 405library. If you 406must process a multi-image file (such as an animation), the <a 407 href="http://www.imagemagick.org/Magick++/STL.html"> STL interface</a> , which provides a multi-image 408abstraction on top of <i>Image</i>, must be used. 409<p>Image manipulation methods are very easy to use. For example: </p> 410<pre class="code"> 411Image image; 412image.read("myImage.tiff"); 413image.addNoise(GaussianNoise); 414image.write("myImage.tiff"); 415</pre> 416adds gaussian noise to the image file "myImage.tiff". 417<p>The operations supported by Image are shown in the following table: <br> 418 419<ul><table nosave="" border="1"> 420 <caption><b>Image Image Manipulation Methods</b></caption> <tbody> 421 <tr align="center"> 422 <td><b>Method</b></td> 423 <td><b>Signature(s)</b></td> 424 <td><b>Description</b></td> 425 </tr> 426 <tr> 427 <td style="text-align: center;" valign="middle"> 428 <div align="center"><a name="adaptiveThreshold"></a> <font 429 size="-1">adaptiveThreshold<br> 430 </font></div> 431 </td> 432 <td valign="middle"><font size="-1">size_t width, size_t 433height, size_t offset = 0<br> 434 </font></td> 435 <td valign="top"><font size="-1">Apply adaptive thresholding to 436the image. Adaptive thresholding is useful if the ideal threshold level 437is not known in advance, or if the illumination gradient is not 438constant 439across the image. Adaptive thresholding works by evaluating the mean 440(average) of a pixel region (size specified by <i>width</i> and <i>height</i>) 441and using the mean as the thresholding value. In order to remove 442residual noise from the background, the threshold may be adjusted by 443subtracting a constant <i>offset</i> (default zero) from the mean to 444compute the threshold.</font><br> 445 </td> 446 </tr> 447 <tr> 448 <td style="text-align: center;"> 449 <center><a name="addNoise"></a> <font size="-1">addNoise</font></center> 450 </td> 451 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#NoiseType">NoiseType</a> 452noiseType_</font></td> 453 <td><font size="-1">Add noise to image with specified noise type.</font></td> 454 </tr> 455 <tr> 456 <td style="vertical-align: middle; text-align: center;"><small><a 457 name="addNoiseChannel"></a>addNoiseChannel<br> 458 </small></td> 459 <td style="vertical-align: middle;"><small>const ChannelType 460channel_, const NoiseType noiseType_<br> 461 </small></td> 462 <td style="vertical-align: middle;"><small>Add noise to an image 463channel with the specified noise type.</small><font size="-1"> The <span 464 style="font-style: italic;">channel_</span> parameter specifies the 465channel to add noise to. The </font><small>noiseType_ parameter 466specifies the type of noise.<br> 467 </small></td> 468 </tr> 469 <tr> 470 <td style="vertical-align: middle; text-align: center;"><small><a 471 name="affineTransform"></a>affineTransform<br> 472 </small></td> 473 <td style="vertical-align: middle;"><small>const DrawableAffine 474&affine<br> 475 </small></td> 476 <td style="vertical-align: middle;"><small>Transform image by 477specified affine (or free transform) matrix.<br> 478 </small></td> 479 </tr> 480 <tr> 481 <td style="text-align: center;" rowspan="4"> 482 <center><a name="annotate"></a> <font size="-1">annotate</font></center> 483 </td> 484 <td><font size="-1">const std::string &text_, const <a 485 href="http://www.imagemagick.org/Magick++/Geometry.html"> Geometry</a> &location_</font></td> 486 <td><font size="-1">Annotate using specified text, and placement 487location</font></td> 488 </tr> 489 <tr> 490 <td><font size="-1">string text_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 491&boundingArea_, <a href="http://www.imagemagick.org/Magick++/Enumerations.html#GravityType">GravityType</a> 492gravity_</font></td> 493 <td><font size="-1">Annotate using specified text, bounding area, 494and placement gravity. If <i>boundingArea_</i> is invalid, then 495bounding area is entire image.</font></td> 496 </tr> 497 <tr> 498 <td><font size="-1">const std::string &text_, const <a 499 href="http://www.imagemagick.org/Magick++/Geometry.html"> Geometry</a> &boundingArea_, <a 500 href="http://www.imagemagick.org/Magick++/Enumerations.html#GravityType">GravityType</a> gravity_, double 501degrees_, </font></td> 502 <td><font size="-1">Annotate with text using specified text, 503bounding area, placement gravity, and rotation. If <i>boundingArea_</i> 504is invalid, then bounding area is entire image.</font></td> 505 </tr> 506 <tr> 507 <td><font size="-1">const std::string &text_, <a 508 href="http://www.imagemagick.org/Magick++/Enumerations.html#GravityType"> GravityType</a> gravity_</font></td> 509 <td><font size="-1">Annotate with text (bounding area is entire 510image) and placement gravity.</font></td> 511 </tr> 512 <tr> 513 <td style="text-align: center;"> 514 <center><a name="blur"></a> <font size="-1">blur</font></center> 515 </td> 516 <td><font size="-1">const double radius_ = 1, const double sigma_ 517= 0.5</font></td> 518 <td><font size="-1">Blur image. The <i>radius_ </i>parameter 519specifies the radius of the Gaussian, in pixels, not counting the 520center 521pixel. The <i>sigma_</i> parameter specifies the standard 522deviation of the Laplacian, in pixels.</font></td> 523 </tr> 524 <tr> 525 <td style="vertical-align: middle; text-align: center;"><small><a 526 name="blurChannel"></a>blurChannel<br> 527 </small></td> 528 <td style="vertical-align: middle;"><small>const ChannelType 529channel_, const double radius_ = 0.0, const double sigma_ = 1.0<br> 530 </small></td> 531 <td style="vertical-align: middle;"><font size="-1">Blur an image 532channel. The <span style="font-style: italic;">channel_</span> 533parameter specifies the channel to blur. The <i>radius_ </i>parameter 534specifies the radius of the Gaussian, in pixels, not counting the 535center 536pixel. The <i>sigma_</i> parameter specifies the standard 537deviation of the Laplacian, in pixels.</font></td> 538 </tr> 539 <tr> 540 <td style="text-align: center;"> 541 <center><a name="border"></a> <font size="-1">border</font></center> 542 </td> 543 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 544&geometry_ = "6x6+0+0"</font></td> 545 <td><font size="-1">Border image (add border to image). The 546color of the border is specified by the <i>borderColor</i> attribute.</font></td> 547 </tr> 548 <tr> 549 <td style="text-align: center;"> 550 <center><a name="cdl"></a> <font size="-1">cdl</font></center> 551 </td> 552 <td><font size="-1">const std::string &cdl_</font></td> 553 <td><font size="-1">color correct with a color decision list. See <a href="http://en.wikipedia.org/wiki/ASC_CDL">http://en.wikipedia.org/wiki/ASC_CDL</a> for details.</font></td> 554 </tr> 555 <tr> 556 <td style="text-align: center;"> 557 <center><a name="channel"></a> <font size="-1">channel</font></center> 558 </td> 559 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ChannelType">ChannelType</a> 560layer_</font></td> 561 <td><font size="-1">Extract channel from image. Use this option 562to extract a particular channel from the image. <i>MatteChannel</i> 563 for example, is useful for extracting the opacity values 564from an image.</font></td> 565 </tr> 566 <tr> 567 <td style="text-align: center;"> 568 <center><a name="charcoal"></a> <font size="-1">charcoal</font></center> 569 </td> 570 <td><font size="-1">const double radius_ = 1, const double sigma_ 571= 0.5</font></td> 572 <td><font size="-1">Charcoal effect image (looks like charcoal 573sketch). The <i>radius_</i> parameter specifies the radius of the 574Gaussian, in pixels, not counting the center pixel. The <i>sigma_</i> 575parameter specifies the standard deviation of the Laplacian, in pixels.</font></td> 576 </tr> 577 <tr> 578 <td style="text-align: center;"> 579 <center><a name="chop"></a> <font size="-1">chop</font></center> 580 </td> 581 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 582&geometry_</font></td> 583 <td><font size="-1">Chop image (remove vertical or horizontal 584subregion of image)</font></td> 585 </tr> 586 <tr> 587 <td style="text-align: center;"> 588 <center><a name="colorize"></a> <font size="-1">colorize</font></center> 589 </td> 590 <td><font size="-1">const unsigned int opacityRed_, const 591unsigned int opacityGreen_, const unsigned int opacityBlue_, const 592Color &penColor_</font></td> 593 <td><font size="-1">Colorize image with pen color, using 594specified percent opacity for red, green, and blue quantums.</font></td> 595 </tr> 596 <tr> 597 <td style="text-align: center;"> 598 <center><a name="colorMatrix"></a> <font size="-1">colorMatrix</font></center> 599 </td> 600 <td><font size="-1">const size_t order_, const double *color_matrix_</font></td> 601 <td><font size="-1">apply color correction to the image.</font></td> 602 </tr> 603 <tr> 604 <td style="text-align: center;"> 605 <center><a name="comment"></a> <font size="-1">comment</font></center> 606 </td> 607 <td><font size="-1">const std::string &comment_</font></td> 608 <td><font size="-1">Comment image (add comment string to 609image). By default, each image is commented with its file name. 610Use this method to assign a specific comment to the 611image. Optionally you can include the image filename, type, 612width, height, or other image attributes by embedding <a 613 href="http://www.imagemagick.org/Magick++/FormatCharacters.html">special format characters.</a> </font></td> 614 </tr> 615 <tr> 616 <td style="text-align: center;" valign="middle"><font size="-1"><a 617 name="compare"></a> compare<br> 618 </font></td> 619 <td valign="middle"><font size="-1">const Image &reference_<br> 620 </font></td> 621 <td valign="top"><font size="-1">Compare current image with 622another image. Sets <a href="Image++.html#meanErrorPerPixel">meanErrorPerPixel</a> 623, <a href="Image++.html#normalizedMaxError">normalizedMaxError</a> , and <a 624 href="Image++.html#normalizedMeanError">normalizedMeanError</a> in the current 625image. False is returned if the images are identical. An ErrorOption 626exception is thrown if the reference image columns, rows, colorspace, 627or 628matte differ from the current image.</font><br> 629 </td> 630 </tr> 631 <tr> 632 <td style="text-align: center;" rowspan="3"> 633 <center><a name="composite"></a> <font size="-1">composite</font></center> 634 </td> 635 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Image.html">Image</a> 636&compositeImage_, ssize_t xOffset_, ssize_t yOffset_, <a 637 href="http://www.imagemagick.org/Magick++/Enumerations.html#CompositeOperator"> CompositeOperator</a> 638compose_ = <i>InCompositeOp</i></font></td> 639 <td><font size="-1">Compose an image onto the current image at 640offset specified by <i>xOffset_</i>, <i>yOffset_ </i>using the 641composition algorithm specified by <i>compose_</i>. </font></td> 642 </tr> 643 <tr> 644 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Image.html">Image</a> 645&compositeImage_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 646&offset_, <a href="http://www.imagemagick.org/Magick++/Enumerations.html#CompositeOperator">CompositeOperator</a> 647compose_ = <i>InCompositeOp</i></font></td> 648 <td><font size="-1">Compose an image onto the current image at 649offset specified by <i>offset_</i> using the composition algorithm 650specified by <i>compose_</i> . </font></td> 651 </tr> 652 <tr> 653 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Image.html">Image</a> 654&compositeImage_, <a href="http://www.imagemagick.org/Magick++/Enumerations.html#GravityType">GravityType</a> 655gravity_, <a href="http://www.imagemagick.org/Magick++/Enumerations.html#CompositeOperator">CompositeOperator</a> 656compose_ = <i>InCompositeOp</i></font></td> 657 <td><font size="-1">Compose an image onto the current image with 658placement specified by <i>gravity_ </i>using the composition 659algorithm 660specified by <i>compose_</i>. </font></td> 661 </tr> 662 <tr> 663 <td style="text-align: center;"> 664 <center><a name="contrast"></a> <font size="-1">contrast</font></center> 665 </td> 666 <td><font size="-1">size_t sharpen_</font></td> 667 <td><font size="-1">Contrast image (enhance intensity differences 668in image)</font></td> 669 </tr> 670 <tr> 671 <td style="text-align: center;"> 672 <center><a name="convolve"></a> <font size="-1">convolve</font></center> 673 </td> 674 <td><font size="-1">size_t order_, const double *kernel_</font></td> 675 <td><font size="-1">Convolve image. Applies a user-specified 676convolution to the image. The <i>order_</i> parameter represents the 677number of columns and rows in the filter kernel, and <i>kernel_</i> 678is a two-dimensional array of doubles representing the convolution 679kernel to apply.</font></td> 680 </tr> 681 <tr> 682 <td style="text-align: center;"> 683 <center><a name="crop"></a> <font size="-1">crop</font></center> 684 </td> 685 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 686&geometry_</font></td> 687 <td><font size="-1">Crop image (subregion of original image)</font></td> 688 </tr> 689 <tr> 690 <td style="text-align: center;"> 691 <center><a name="cycleColormap"></a> <font size="-1">cycleColormap</font></center> 692 </td> 693 <td><font size="-1">int amount_</font></td> 694 <td><font size="-1">Cycle image colormap</font></td> 695 </tr> 696 <tr> 697 <td style="text-align: center;"> 698 <center><a name="despeckle"></a> <font size="-1">despeckle</font></center> 699 </td> 700 <td><font size="-1">void</font></td> 701 <td><font size="-1">Despeckle image (reduce speckle noise)</font></td> 702 </tr> 703 <tr> 704 <td style="text-align: center;"> 705 <center><a name="display"></a> <font size="-1">display</font></center> 706 </td> 707 <td><font size="-1">void</font></td> 708 <td><font size="-1">Display image on screen.</font> <br> 709 <font size="-1"><b><font color="#ff0000">Caution: </font></b> if 710an image format is is not compatible with the display visual (e.g. 711JPEG on a colormapped display) then the original image will be 712altered. Use a copy of the original if this is a problem.</font></td> 713 </tr> 714 <tr> 715 <td> 716 <center><a name="distort"></a> <font size="-1">distort</font></center> 717 </td> 718 <td><font size="-1">const DistortImageMethod method, const size_t number_arguments, const double *arguments, const bool bestfit = false </font></td> 719 <td><font size="-1">Distort image. Applies a user-specified 720distortion to the image.</font></td> 721 </tr> 722 <tr> 723 <td style="text-align: center;" rowspan="2"> 724 <center><a name="draw"></a> <font size="-1">draw</font></center> 725 </td> 726 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Drawable.html">Drawable</a> 727&drawable_</font></td> 728 <td><font size="-1">Draw shape or text on image.</font></td> 729 </tr> 730 <tr> 731 <td><font size="-1">const std::list<<a href="http://www.imagemagick.org/Magick++/Drawable.html">Drawable</a> 732> &drawable_</font></td> 733 <td><font size="-1">Draw shapes or text on image using a set of 734Drawable objects contained in an STL list. Use of this method improves 735drawing performance and allows batching draw objects together in a 736list for repeated use.</font></td> 737 </tr> 738 <tr> 739 <td style="text-align: center;"> 740 <center><a name="edge"></a> <font size="-1">edge</font></center> 741 </td> 742 <td><font size="-1">size_t radius_ = 0.0</font></td> 743 <td><font size="-1">Edge image (hilight edges in image). 744The radius is the radius of the pixel neighborhood.. Specify a radius 745of zero for automatic radius selection.</font></td> 746 </tr> 747 <tr> 748 <td style="text-align: center;"> 749 <center><a name="emboss"></a> <font size="-1">emboss</font></center> 750 </td> 751 <td><font size="-1">const double radius_ = 1, const double sigma_ 752= 0.5</font></td> 753 <td><font size="-1">Emboss image (hilight edges with 3D effect). 754The <i> radius_</i> parameter specifies the radius of the Gaussian, in 755pixels, not counting the center pixel. The <i>sigma_</i> 756parameter specifies the standard deviation of the Laplacian, in pixels.</font></td> 757 </tr> 758 <tr> 759 <td style="text-align: center;"> 760 <center><a name="enhance"></a> <font size="-1">enhance</font></center> 761 </td> 762 <td><font size="-1">void</font></td> 763 <td><font size="-1">Enhance image (minimize noise)</font></td> 764 </tr> 765 <tr> 766 <td style="text-align: center;"> 767 <center><a name="equalize"></a> <font size="-1">equalize</font></center> 768 </td> 769 <td><font size="-1">void</font></td> 770 <td><font size="-1">Equalize image (histogram equalization)</font></td> 771 </tr> 772 <tr> 773 <td style="text-align: center;"> 774 <center><a name="erase"></a> <font size="-1">erase</font></center> 775 </td> 776 <td><font size="-1">void</font></td> 777 <td><font size="-1">Set all image pixels to the current 778background color.</font></td> 779 </tr> 780 <tr> 781 <td style="text-align: center;" rowspan="4"> 782 <center><a name="extent"></a> <font size="-1">extent</font></td> 783 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html"> Geometry</a> &geometry_</font></td> 784 <td rowspan="2"><font size="-1">extends the image as defined by the geometry, gravity, and image background color.</font></td> 785 </tr> 786 <tr> 787 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 788&geometry_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &backgroundColor_</font></td> 789 </tr> 790 <tr> 791 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html"> Geometry</a> &geometry_, const <a href="../../api/Enumerations.html#GravityType">GravityType</a> 792&gravity_</font></td> 793 <td rowspan="2"><font size="-1">extends the image as defined by the geometry, gravity, and image background color.</font></td> 794 </tr> 795 <tr> 796 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 797&geometry_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &backgroundColor_, 798const <a href="http://www.imagemagick.org/Magick++/Enumerations.html#GravityType">GravityType</a> &gravity_</font></td> 799 </tr> 800 <tr> 801 <td style="text-align: center;"> 802 <center><a name="flip"></a> <font size="-1">flip</font></center> 803 </td> 804 <td><font size="-1">void</font></td> 805 <td><font size="-1">Flip image (reflect each scanline in the 806vertical direction)</font></td> 807 </tr> 808 <tr> 809 <td style="text-align: center;" rowspan="4"> 810 <center><a name="floodFillColor"></a> <font size="-1">floodFill-</font> 811 <br> 812 <font size="-1">Color</font></center> 813 </td> 814 <td><font size="-1">ssize_t x_, ssize_t y_, const <a 815 href="http://www.imagemagick.org/Magick++/Color.html"> Color</a> &fillColor_</font></td> 816 <td rowspan="2"><font size="-1">Flood-fill color across pixels 817that match the color of the target pixel and are neighbors of the 818target pixel. Uses current fuzz setting when determining color match.</font></td> 819 </tr> 820 <tr> 821 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 822&point_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &fillColor_</font></td> 823 </tr> 824 <tr> 825 <td><font size="-1">ssize_t x_, ssize_t y_, const <a 826 href="http://www.imagemagick.org/Magick++/Color.html"> Color</a> &fillColor_, const <a 827 href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 828&borderColor_</font></td> 829 <td rowspan="2"><font size="-1">Flood-fill color across pixels 830starting at target-pixel and stopping at pixels matching specified 831border color. Uses current fuzz setting when determining color match.</font></td> 832 </tr> 833 <tr> 834 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 835&point_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &fillColor_, 836const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &borderColor_</font></td> 837 </tr> 838 <tr> 839 <td style="text-align: center;"><a name="floodFillOpacity"></a> <font 840 size="-1">floodFillOpacity</font></td> 841 <td><font size="-1">const long x_, const long y_, const unsigned int 842opacity_, const PaintMethod method_</font></td> 843 <td><font size="-1">Floodfill pixels matching color (within fuzz 844factor) of target pixel(x,y) with replacement opacity value using 845method.</font></td> 846 </tr> 847 <tr> 848 <td style="text-align: center;" rowspan="4"> 849 <center><a name="floodFillTexture"></a> <font size="-1">floodFill-</font> 850 <br> 851 <font size="-1">Texture</font></center> 852 </td> 853 <td><font size="-1">ssize_t x_, ssize_t y_, const 854Image &texture_</font></td> 855 <td rowspan="2"><font size="-1">Flood-fill texture across pixels 856that match the color of the target pixel and are neighbors of the 857target pixel. Uses current fuzz setting when determining color match.</font></td> 858 </tr> 859 <tr> 860 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 861&point_, const Image &texture_</font></td> 862 </tr> 863 <tr> 864 <td><font size="-1">ssize_t x_, ssize_t y_, const Image 865&texture_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &borderColor_</font></td> 866 <td rowspan="2"><font size="-1">Flood-fill texture across pixels 867starting at target-pixel and stopping at pixels matching specified 868border color. Uses current fuzz setting when determining color match.</font></td> 869 </tr> 870 <tr> 871 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 872&point_, const Image &texture_, const <a href="http://www.imagemagick.org/Magick++/Color.html"> 873Color</a> 874&borderColor_</font></td> 875 </tr> 876 <tr> 877 <td style="text-align: center;"> 878 <center><a name="flop"></a> <font size="-1">flop</font></center> 879 </td> 880 <td><font size="-1">void </font></td> 881 <td><font size="-1">Flop image (reflect each scanline in the 882horizontal direction)</font></td> 883 </tr> 884 <tr> 885 <td style="text-align: center;" rowspan="2"> 886 <center><a name="frame"></a> <font size="-1">frame</font></center> 887 </td> 888 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 889&geometry_ = "25x25+6+6"</font></td> 890 <td rowspan="2"><font size="-1">Add decorative frame around image</font></td> 891 </tr> 892 <tr> 893 <td><font size="-1">size_t width_, size_t height_, 894ssize_t x_, ssize_t y_, ssize_t innerBevel_ = 0, ssize_t outerBevel_ = 0</font></td> 895 </tr> 896 <tr> 897 <td> 898 <center><a name="fx"></a> <font size="-1">fx</font></center> 899 </td> 900 <td><font size="-1">const std::string expression, const Magick::ChannelType channel</font></td> 901 <td><font size="-1">Fx image. Applies a mathematical 902expression to the image.</font></td> 903 </tr> 904 <tr> 905 <td style="text-align: center;" rowspan="2"> 906 <center><a name="gamma"></a> <font size="-1">gamma</font></center> 907 </td> 908 <td><font size="-1">double gamma_</font></td> 909 <td><font size="-1">Gamma correct image (uniform red, green, and 910blue correction).</font></td> 911 </tr> 912 <tr> 913 <td><font size="-1">double gammaRed_, double gammaGreen_, double 914gammaBlue_</font></td> 915 <td><font size="-1">Gamma correct red, green, and blue channels 916of image.</font></td> 917 </tr> 918 <tr> 919 <td style="text-align: center;"> 920 <center><a name="gaussianBlur"></a> <font size="-1">gaussianBlur</font></center> 921 </td> 922 <td><font size="-1">const double width_, const double sigma_</font></td> 923 <td><font size="-1">Gaussian blur image. The number of neighbor 924pixels to be included in the convolution mask is specified by 925'width_'. For example, a width of one gives a (standard) 3x3 926convolution mask. The standard deviation of the gaussian bell curve is 927specified by 'sigma_'.</font></td> 928 </tr> 929 <tr> 930 <td style="vertical-align: middle; text-align: center;"><small><a 931 name="gaussianBlurChannel"></a>gaussianBlurChannel<br> 932 </small></td> 933 <td style="vertical-align: middle;"><small>const ChannelType 934channel_, const double radius_ = 0.0, const double sigma_ = 1.0<br> 935 </small></td> 936 <td style="vertical-align: middle;"><font size="-1">Gaussian blur 937an image channel. </font><font size="-1">The <span 938 style="font-style: italic;">channel_</span> parameter specifies the 939channel to blur. </font><font size="-1">The number of neighbor 940pixels to be included in the convolution mask is specified by 941'width_'. For example, a width of one gives a (standard) 3x3 942convolution mask. The standard deviation of the gaussian bell curve is 943specified by 'sigma_'.</font></td> 944 </tr> 945 <tr> 946 <td style="text-align: center;" valign="middle"><font size="-1"><a 947 name="haldClut"></a> haldClut<br> 948 </font></td> 949 <td valign="middle"><font size="-1">const Image &reference_<br> 950 </font></td> 951 <td valign="top"><font size="-1">apply a Hald color lookup table to the image.</font><br> 952 </td> 953 </tr> 954 <tr> 955 <td style="text-align: center;"> 956 <center><a name="implode"></a> <font size="-1">implode</font></center> 957 </td> 958 <td><font size="-1">const double factor_</font></td> 959 <td><font size="-1">Implode image (special effect)</font></td> 960 </tr> 961 <tr> 962 <td style="text-align: center;"> 963 <center><a name="inverseFourierTransform"></a> <font size="-1">inverseFourierTransform</font></center> 964 </td> 965 <td><font size="-1">const Image &phaseImage_, const bool magnitude_</font></td> 966 <td><font size="-1">implements the inverse discrete Fourier transform (DFT) of the image either as a magnitude / phase or real / imaginary image pair.</font></td> 967 </tr> 968 <tr> 969 <td style="text-align: center;"> 970 <center><a name="label"></a> <font size="-1">label</font></center> 971 </td> 972 <td><font size="-1">const string &label_</font></td> 973 <td><font size="-1">Assign a label to an image. Use this option 974to assign a specific label to the image. Optionally 975you can include the image filename, type, width, height, or scene 976number in the label by embedding <a href="http://www.imagemagick.org/Magick++/FormatCharacters.html"> 977special format characters.</a> If the first character of string is @, 978the 979image label is read from a file titled by the remaining characters in 980the string. When converting to Postscript, use this option to 981specify a header string to print above the image.</font></td> 982 </tr> 983 <tr> 984 <td style="vertical-align: top; text-align: center;"><small><a 985 name="level"></a>level<br> 986 </small></td> 987 <td style="vertical-align: top;"><small>const double black_point, 988const double white_point, const double mid_point=1.0<br> 989 </small></td> 990 <td style="vertical-align: top;"><small>Level image. Adjust the 991levels of the image by scaling the colors falling between specified 992white and black points to the full available quantum range. The 993parameters provided represent the black, mid (gamma), and white 994points. The black point specifies the darkest color in the image. 995Colors darker than the black point are set to zero. Mid point (gamma) 996specifies a gamma correction to apply to the image. White point 997specifies the lightest color in the image. Colors brighter than 998the white point are set to the maximum quantum value. The black and 999white point have the valid range 0 to MaxRGB while mid (gamma) has a 1000useful range of 0 to ten.<br> 1001 </small></td> 1002 </tr> 1003 <tr> 1004 <td style="vertical-align: middle; text-align: center;"><small><a 1005 name="levelChannel"></a>levelChannel<br> 1006 </small></td> 1007 <td style="vertical-align: middle;"><small>const ChannelType 1008channel, const double black_point, const double white_point, const 1009double mid_point=1.0<br> 1010 </small></td> 1011 <td style="vertical-align: middle;"><small>Level image channel. 1012Adjust the levels of the image channel by scaling the values falling 1013between specified white and black points to the full available quantum 1014range. The parameters provided represent the black, mid (gamma), and 1015white points. The black point specifies the darkest color in the image. 1016Colors darker than the black point are set to zero. Mid point (gamma) 1017specifies a gamma correction to apply to the image. White point 1018specifies the lightest color in the image. Colors brighter than the 1019white point are set to the maximum quantum value. The black and white 1020point have the valid range 0 to MaxRGB while mid (gamma) has a useful 1021range of 0 to ten.<br> 1022 </small></td> 1023 </tr> 1024 <tr> 1025 <td style="text-align: center;"> 1026 <center><a name="magnify"></a> <font size="-1">magnify</font></center> 1027 </td> 1028 <td><font size="-1">void</font></td> 1029 <td><font size="-1">Magnify image by integral size</font></td> 1030 </tr> 1031 <tr> 1032 <td style="text-align: center;"> 1033 <center><a name="map"></a> <font size="-1">map</font></center> 1034 </td> 1035 <td><font size="-1">const Image &mapImage_ , bool dither_ = 1036false</font></td> 1037 <td><font size="-1">Remap image colors with closest color from 1038reference image. Set dither_ to <i>true</i> in to apply 1039Floyd/Steinberg 1040error diffusion to the image. By default, color reduction chooses an 1041optimal set of colors that best represent the original 1042image. Alternatively, you can choose a 1043particular set of colors from an image file 1044with this option.</font></td> 1045 </tr> 1046 <tr> 1047 <td style="text-align: center;"> 1048 <center><a name="matteFloodfill"></a> <font size="-1">matteFloodfill</font></center> 1049 </td> 1050 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1051&target_, const unsigned int opacity_, const ssize_t x_, const 1052ssize_t 1053y_, <a href="http://www.imagemagick.org/Magick++/Enumerations.html#PaintMethod">PaintMethod</a> method_</font></td> 1054 <td><font size="-1">Floodfill designated area with a replacement 1055opacity value.</font></td> 1056 </tr> 1057 <tr> 1058 <td style="text-align: center;"><a name="medianFilter"></a> <font 1059 size="-1">medianFilter</font></td> 1060 <td><font size="-1">const double radius_ = 0.0</font></td> 1061 <td><font size="-1">Filter image by replacing each pixel 1062component with the median color in a circular neighborhood</font></td> 1063 </tr> 1064 <tr> 1065 <td style="text-align: center;"> 1066 <center><a name="mergeLayers"></a> <font size="-1">mergeLayers</font></center> 1067 </td> 1068 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#LayerMethod">LayerMethod</a> 1069noiseType_</font></td> 1070 <td><font size="-1">handle multiple images forming a set of image layers or animation frames.</font></td> 1071 </tr> 1072 <tr> 1073 <td style="text-align: center;"> 1074 <center><a name="minify"></a> <font size="-1">minify</font></center> 1075 </td> 1076 <td><font size="-1">void</font></td> 1077 <td><font size="-1">Reduce image by integral size</font></td> 1078 </tr> 1079 <tr> 1080 <td style="text-align: center;"><a name="modifyImage"></a> <font 1081 size="-1">modifyImage</font></td> 1082 <td><font size="-1">void</font></td> 1083 <td><font size="-1">Prepare to update image. Ensures that there 1084is only one reference to the underlying image so that the underlying 1085image may be safely modified without effecting previous generations of 1086the image. Copies the underlying image to a new image if necessary.</font></td> 1087 </tr> 1088 <tr> 1089 <td style="text-align: center;"> 1090 <center><a name="modulate"></a> <font size="-1">modulate</font></center> 1091 </td> 1092 <td><font size="-1">double brightness_, double saturation_, 1093double hue_</font></td> 1094 <td><font size="-1">Modulate percent hue, saturation, and 1095brightness of an image. Modulation of saturation and brightness is as a 1096ratio of the current value (1.0 for no change). Modulation of hue is an 1097absolute rotation of -180 degrees to +180 degrees from the current 1098position corresponding to an argument range of 0 to 2.0 (1.0 for no 1099change).</font></td> 1100 </tr> 1101 <tr> 1102 <td style="vertical-align: middle; text-align: center;"><small><a 1103 name="motionBlur"></a>motionBlur<br> 1104 </small></td> 1105 <td style="vertical-align: middle;"><small>const double radius_, 1106const double sigma_, const double angle_<br> 1107 </small></td> 1108 <td style="vertical-align: middle;"><small>Motion blur image with 1109specified blur factor. The radius_ parameter specifies the radius of 1110the Gaussian, in pixels, not counting the center pixel. The 1111sigma_ parameter specifies the standard deviation of the Laplacian, in 1112pixels. The angle_ parameter specifies the angle the object appears to 1113be coming from (zero degrees is from the right).<br> 1114 </small></td> 1115 </tr> 1116 <tr> 1117 <td style="text-align: center;"> 1118 <center><a name="negate"></a> <font size="-1">negate</font></center> 1119 </td> 1120 <td><font size="-1">bool grayscale_ = false</font></td> 1121 <td><font size="-1">Negate colors in image. Replace every 1122pixel with its complementary color (white becomes black, yellow becomes 1123blue, etc.). Set grayscale to only negate grayscale values in 1124image.</font></td> 1125 </tr> 1126 <tr> 1127 <td style="text-align: center;"> 1128 <center><a name="normalize"></a> <font size="-1">normalize</font></center> 1129 </td> 1130 <td><font size="-1">void</font></td> 1131 <td><font size="-1">Normalize image (increase contrast by 1132normalizing the pixel values to span the full range of color values).</font></td> 1133 </tr> 1134 <tr> 1135 <td style="text-align: center;"> 1136 <center><a name="oilPaint"></a> <font size="-1">oilPaint</font></center> 1137 </td> 1138 <td><font size="-1">size_t radius_ = 3</font></td> 1139 <td><font size="-1">Oilpaint image (image looks like oil painting)</font></td> 1140 </tr> 1141 <tr> 1142 <td style="text-align: center;"> 1143 <center><a name="opacity"></a> <font size="-1">opacity</font></center> 1144 </td> 1145 <td><font size="-1">unsigned int opacity_</font></td> 1146 <td><font size="-1">Set or attenuate the opacity channel in the 1147image. If the image pixels are opaque then they are set to the 1148specified 1149opacity value, otherwise they are blended with the supplied opacity 1150value. The value of opacity_ ranges from 0 (completely opaque) to 1151 <i>MaxRGB</i> 1152. The defines <i>OpaqueOpacity</i> and <i>TransparentOpacity</i> are 1153available to specify completely opaque or completely transparent, 1154respectively.</font></td> 1155 </tr> 1156 <tr> 1157 <td style="text-align: center;"> 1158 <center><a name="opaque"></a> <font size="-1">opaque</font></center> 1159 </td> 1160 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1161&opaqueColor_, const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> &penColor_</font></td> 1162 <td><font size="-1">Change color of pixels matching opaqueColor_ 1163to specified penColor_.</font></td> 1164 </tr> 1165 <tr nosave=""> 1166 <td style="text-align: center;" rowspan="2" nosave=""> 1167 <center><a name="ping"></a> <font size="-1">ping</font></center> 1168 </td> 1169 <td><font size="-1">const std::string &imageSpec_</font></td> 1170 <td rowspan="2" nosave=""><font size="-1">Ping is similar to read 1171except only enough of the image is read to determine the image columns, 1172rows, and filesize. The <a href="Image++.html#columns">columns</a> </font>, 1173 <font size="-1"><a href="Image++.html#rows">rows</a> , and <a 1174 href="Image++.html#fileSize">fileSize</a> 1175attributes are valid after invoking ping. The image data is not 1176valid after calling ping.</font></td> 1177 </tr> 1178 <tr> 1179 <td><font size="-1">const Blob &blob_</font></td> 1180 </tr> 1181 <tr> 1182 <td style="vertical-align: middle; text-align: center;"><small><a 1183 name="process"></a>process<br> 1184 </small></td> 1185 <td style="vertical-align: middle;"><small>std::string name_, 1186const ssize_t argc_, char **argv_<br> 1187 </small></td> 1188 <td style="vertical-align: middle;"><small>Execute the named 1189process module, passing any arguments via an argument vector, with 1190argc_ 1191specifying the number of arguments in the vector, and argv_ passing the 1192address of an array of null-terminated C strings which constitute the 1193argument vector. An exception is thrown if the requested process module 1194does not exist, fails to load, or fails during execution.</small><br> 1195 </td> 1196 </tr> 1197 <tr> 1198 <td style="text-align: center;"> 1199 <center><a name="quantize"></a> <font size="-1">quantize</font></center> 1200 </td> 1201 <td><font size="-1">bool measureError_ = false</font></td> 1202 <td><font size="-1">Quantize image (reduce number of colors). Set 1203measureError_ to true in order to calculate error attributes.</font></td> 1204 </tr> 1205 <tr> 1206 <td style="text-align: center;"> 1207 <center><a name="raise"></a> <font size="-1">raise</font></center> 1208 </td> 1209 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1210&geometry_ = "6x6+0+0", bool raisedFlag_ = false</font></td> 1211 <td><font size="-1">Raise image (lighten or darken the edges of 1212an image to give a 3-D raised or lowered effect)</font></td> 1213 </tr> 1214 <tr> 1215 <td style="text-align: center;" rowspan="8"> 1216 <center><a name="read"></a> <font size="-1">read</font></center> 1217 </td> 1218 <td><font size="-1">const string &imageSpec_</font></td> 1219 <td><font size="-1">Read image into current object</font></td> 1220 </tr> 1221 <tr> 1222 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1223&size_, const std::string &imageSpec_</font></td> 1224 <td><font size="-1">Read image of specified size into current 1225object. This form is useful for images that do not specify their size 1226or to specify a size hint for decoding an image. For example, when 1227reading a Photo CD, JBIG, or JPEG image, a size request causes the 1228library to return an image which is the next resolution greater or 1229equal to the specified size. This may result in memory and time savings.</font></td> 1230 </tr> 1231 <tr> 1232 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> &blob_</font></td> 1233 <td rowspan="5"><font size="-1">Read encoded image of specified 1234size from an in-memory <a href="http://www.imagemagick.org/Magick++/Blob.html">BLOB</a> into current 1235object. Depending on the method arguments, the Blob size, depth, and 1236format may also be specified. Some image formats require that size be 1237specified. The default ImageMagick uses for depth depends on its 1238Quantum size (8 or 16). If ImageMagick's Quantum size does not 1239match that of the image, the depth may need to be specified. 1240ImageMagick can usually automagically detect the image's format. 1241When 1242a format can't be automagically detected, the format must be specified.</font></td> 1243 </tr> 1244 <tr> 1245 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 1246&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size_</font></td> 1247 </tr> 1248 <tr> 1249 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 1250&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size_, 1251size_t depth_</font></td> 1252 </tr> 1253 <tr> 1254 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 1255&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size_, 1256size_t depth_, const string &magick_ </font></td> 1257 </tr> 1258 <tr> 1259 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 1260&blob_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> &size_, 1261const 1262string &magick_</font></td> 1263 </tr> 1264 <tr> 1265 <td><font size="-1">const size_t width_, const size_t 1266height_, std::string map_, const StorageType type_, const void *pixels_</font></td> 1267 <td><font size="-1">Read image based on an array of image pixels. 1268The pixel data must be in scanline order top-to-bottom. The data can be 1269character, short int, integer, float, or double. Float and double 1270require the pixels to be normalized [0..1]. The other types are 1271[0..MaxRGB]. For example, to create a 640x480 image from 1272unsigned red-green-blue character data, use</font> 1273 <p><font size="-1"> image.read( 640, 480, "RGB", CharPixel, 1274pixels );</font> </p> 1275 <p><font size="-1">The parameters are as follows:</font> <br> 1276 1277 <table border="0" width="100%"> 1278 <tbody> 1279 <tr> 1280 <td><font size="-1">width_</font></td> 1281 <td><font size="-1">Width in pixels of the image.</font></td> 1282 </tr> 1283 <tr> 1284 <td><font size="-1">height_</font></td> 1285 <td><font size="-1">Height in pixels of the image.</font></td> 1286 </tr> 1287 <tr> 1288 <td><font size="-1">map_</font></td> 1289 <td><font size="-1">This character string can be any 1290combination or order of R = red, G = green, B = blue, A = alpha, C = 1291cyan, Y = yellow M = magenta, and K = black. The ordering reflects the 1292order of the pixels in the supplied pixel array.</font></td> 1293 </tr> 1294 <tr> 1295 <td><font size="-1">type_</font></td> 1296 <td><font size="-1">Pixel storage type (CharPixel, 1297ShortPixel, IntegerPixel, FloatPixel, or DoublePixel)</font></td> 1298 </tr> 1299 <tr> 1300 <td><font size="-1">pixels_</font></td> 1301 <td><font size="-1">This array of values contain the pixel 1302components as defined by the map_ and type_ parameters. The length of 1303the arrays must equal the area specified by the width_ and height_ 1304values and type_ parameters.</font></td> 1305 </tr> 1306 </tbody> 1307 </table> 1308 </p> 1309 </td> 1310 </tr> 1311 <tr> 1312 <td style="text-align: center;"> 1313 <center><a name="reduceNoise"></a> <font size="-1">reduceNoise</font></center> 1314 </td> 1315 <td><font size="-1">const double order_</font></td> 1316 <td><font size="-1">reduce noise in image using a noise peak elimination filter.</font></td> 1317 </tr> 1318 <tr> 1319 <td style="vertical-align: middle; text-align: center;"><small><a 1320 name="randomThreshold"></a>randomThreshold<br> 1321 </small></td> 1322 <td style="vertical-align: middle;"><small>const Geometry 1323&thresholds_<br> 1324 </small></td> 1325 <td style="vertical-align: middle;"><small>Random threshold the 1326image. Changes the value of individual pixels based on the intensity of 1327each pixel compared to a random threshold. The result is a 1328low-contrast, two color image. The thresholds_ argument is a 1329geometry containing LOWxHIGH thresholds. If the string contains 13302x2, 3x3, or 4x4, then an ordered dither of order 2, 3, or 4 will be 1331performed instead. This is a very fast alternative to 'quantize' based 1332dithering.<br> 1333 </small></td> 1334 </tr> 1335 <tr> 1336 <td style="vertical-align: middle; text-align: center;"><small><a 1337 name="randomThresholdChannel"></a>randomThresholdChannel<br> 1338 </small></td> 1339 <td style="vertical-align: middle;"><small>const Geometry 1340&thresholds_, const ChannelType channel_<br> 1341 </small></td> 1342 <td style="vertical-align: middle;"><small>Random threshold an 1343image channel. Similar to <a href="Image++.html#randomThreshold">randomThreshold</a>() 1344but restricted to the specified channel.<br> 1345 </small></td> 1346 </tr> 1347 <tr> 1348 <td style="text-align: center;"> 1349 <center><a name="roll"></a> <font size="-1">roll</font></center> 1350 </td> 1351 <td><font size="-1">int columns_, ssize_t rows_</font></td> 1352 <td><font size="-1">Roll image (rolls image vertically and 1353horizontally) by specified number of columns and rows)</font></td> 1354 </tr> 1355 <tr> 1356 <td style="text-align: center;"> 1357 <center><a name="rotate"></a> <font size="-1">rotate</font></center> 1358 </td> 1359 <td><font size="-1">double degrees_</font></td> 1360 <td><font size="-1">Rotate image counter-clockwise by specified 1361number of degrees.</font></td> 1362 </tr> 1363 <tr> 1364 <td style="text-align: center;"> 1365 <center><a name="sample"></a> <font size="-1">sample</font></center> 1366 </td> 1367 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1368&geometry_ </font></td> 1369 <td><font size="-1">Resize image by using pixel sampling algorithm</font></td> 1370 </tr> 1371 <tr> 1372 <td style="text-align: center;"> 1373 <center><a name="scale"></a> <font size="-1">scale</font></center> 1374 </td> 1375 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1376&geometry_</font></td> 1377 <td><font size="-1">Resize image by using simple ratio algorithm</font></td> 1378 </tr> 1379 <tr> 1380 <td style="text-align: center;"> 1381 <center><a name="segment"></a> <font size="-1">segment</font></center> 1382 </td> 1383 <td><font size="-1">double clusterThreshold_ = 1.0,</font> <br> 1384 <font size="-1">double smoothingThreshold_ = 1.5</font></td> 1385 <td><font size="-1">Segment (coalesce similar image components) 1386by analyzing the histograms of the color components and identifying 1387units that are homogeneous with the fuzzy c-means technique. Also uses <i>quantizeColorSpace</i> 1388and <i>verbose</i> image attributes. Specify <i> clusterThreshold_</i> 1389, 1390as the number of pixels each cluster must 1391exceed 1392the cluster threshold to be considered valid. <i>SmoothingThreshold_</i> 1393eliminates noise in the second derivative of the histogram. As 1394the 1395value is increased, you can expect a smoother 1396second derivative. The default is 1.5.</font></td> 1397 </tr> 1398 <tr> 1399 <td style="text-align: center;"> 1400 <center><a name="shade"></a> <font size="-1">shade</font></center> 1401 </td> 1402 <td><font size="-1">double azimuth_ = 30, double elevation_ = 30,</font> 1403 <br> 1404 <font size="-1">bool colorShading_ = false</font></td> 1405 <td><font size="-1">Shade image using distant light source. 1406Specify <i> azimuth_</i> and <i>elevation_</i> as the 1407position of the light source. By default, the shading 1408results as a grayscale image.. Set c<i>olorShading_</i> to <i>true</i> 1409to 1410shade the red, green, and blue components of the image.</font></td> 1411 </tr> 1412 <tr> 1413 <td style="text-align: center;"> 1414 <center><a name="shadow"></a> <font size="-1">shadow</font></center> 1415 </td> 1416 <td><font size="-1">const double percent_opacity = 80, const double sigma_ 1417= 0.5, const ssize_t x_ = 0, const ssize_t y_ = 0</font></td> 1418 <td><font size="-1">simulate an image shadow</font></td> 1419 </tr> 1420 <tr> 1421 <td style="text-align: center;"> 1422 <center><a name="sharpen"></a> <font size="-1">sharpen</font></center> 1423 </td> 1424 <td><font size="-1">const double radius_ = 1, const double sigma_ 1425= 0.5</font></td> 1426 <td><font size="-1">Sharpen pixels in image. The <i>radius_</i> 1427parameter specifies the radius of the Gaussian, in pixels, not counting 1428the center pixel. The <i>sigma_</i> parameter specifies the 1429standard deviation of the Laplacian, in pixels.</font></td> 1430 </tr> 1431 <tr> 1432 <td style="vertical-align: middle; text-align: center;"><small><a 1433 name="sharpenChannel"></a>sharpenChannel<br> 1434 </small></td> 1435 <td style="vertical-align: middle;"><small>const ChannelType 1436channel_, const double radius_ = 0.0, const double sigma_ = 1.0<br> 1437 </small></td> 1438 <td style="vertical-align: middle;"><font size="-1">Sharpen pixel 1439quantums in an image channel The <span 1440 style="font-style: italic;">channel_</span> parameter specifies the 1441channel to sharpen.. The <i>radius_</i> 1442parameter specifies the radius of the Gaussian, in pixels, not counting 1443the center pixel. The <i>sigma_</i> parameter specifies the 1444standard deviation of the Laplacian, in pixels.</font></td> 1445 </tr> 1446 <tr> 1447 <td style="text-align: center;"> 1448 <center><a name="shave"></a> <font size="-1">shave</font></center> 1449 </td> 1450 <td><font size="-1">const Geometry &geometry_</font></td> 1451 <td><font size="-1">Shave pixels from image edges.</font></td> 1452 </tr> 1453 <tr> 1454 <td style="text-align: center;"> 1455 <center><a name="shear"></a> <font size="-1">shear</font></center> 1456 </td> 1457 <td><font size="-1">double xShearAngle_, double yShearAngle_</font></td> 1458 <td><font size="-1">Shear image (create parallelogram by sliding 1459image by X or Y axis). Shearing slides one edge of an image along 1460the X or Y axis, creating a 1461parallelogram. An X direction shear slides an edge along the X 1462axis, while a Y direction shear slides 1463an edge along the Y axis. The amount of the shear is controlled 1464by a shear angle. For X direction shears, x 1465degrees is measured relative to the Y axis, and similarly, for Y 1466direction shears y degrees is measured relative to the X 1467axis. Empty triangles left over from shearing the image are 1468filled with the color defined as <i>borderColor</i>. </font></td> 1469 </tr> 1470 <tr> 1471 <td style="text-align: center;"> 1472 <center><a name="solarize"></a> <font size="-1">solarize</font></center> 1473 </td> 1474 <td><font size="-1">double factor_ = 50.0</font></td> 1475 <td><font size="-1">Solarize image (similar to effect seen when 1476exposing a photographic film to light during the development process)</font></td> 1477 </tr> 1478 <tr> 1479 <td style="text-align: center;"> 1480 <center><a name="splice"></a> <font size="-1">splice</font></center> 1481 </td> 1482 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1483&geometry_</font></td> 1484 <td><font size="-1">splice the background color into the image</font></td> 1485 </tr> 1486 <tr> 1487 <td style="text-align: center;"> 1488 <center><a name="spread"></a> <font size="-1">spread</font></center> 1489 </td> 1490 <td><font size="-1">size_t amount_ = 3</font></td> 1491 <td><font size="-1">Spread pixels randomly within image by 1492specified amount</font></td> 1493 </tr> 1494 <tr> 1495 <td style="text-align: center;"> 1496 <center><a name="stegano"></a> <font size="-1">stegano</font></center> 1497 </td> 1498 <td><font size="-1">const Image &watermark_</font></td> 1499 <td><font size="-1">Add a digital watermark to the image (based 1500on second image)</font></td> 1501 </tr> 1502 <tr> 1503 <td> 1504 <center><a name="sparseColor"></a> <font size="-1">sparseColor</font></center> 1505 </td> 1506 <td><font size="-1">const ChannelType channel, const SparseColorMethod method, const size_t number_arguments, const double *arguments </font></td> 1507 <td><font size="-1">Sparse color image, given a set of coordinates, interpolates the colors found at those coordinates, across the whole image, using various methods.</font></td> 1508 </tr> 1509 <tr> 1510 <td style="text-align: center;"> 1511 <center><a name="statistics"></a> <font size="-1">statistics</font></center> 1512 </td> 1513 <td><font size="-1">ImageStatistics *statistics</font></td> 1514 <td><font size="-1">Obtain image statistics. Statistics are normalized to the range of 0.0 to 1.0 and are output to the specified ImageStatistics structure. The structure includes members maximum, minimum, mean, standard_deviation, and variance for each of these channels: red, green, blue, and opacity (e.g. statistics->red.maximum).</font></td> 1515 </tr> 1516 <tr> 1517 <td style="text-align: center;"> 1518 <center><a name="stereo"></a> <font size="-1">stereo</font></center> 1519 </td> 1520 <td><font size="-1">const Image &rightImage_</font></td> 1521 <td><font size="-1">Create an image which appears in stereo when 1522viewed with red-blue glasses (Red image on left, blue on right)</font></td> 1523 </tr> 1524 <tr> 1525 <td style="text-align: center;"> 1526 <center><a name="swirl"></a> <font size="-1">swirl</font></center> 1527 </td> 1528 <td><font size="-1">double degrees_</font></td> 1529 <td><font size="-1">Swirl image (image pixels are rotated by 1530degrees)</font></td> 1531 </tr> 1532 <tr> 1533 <td style="text-align: center;"> 1534 <center><a name="texture"></a> <font size="-1">texture</font></center> 1535 </td> 1536 <td><font size="-1">const Image &texture_</font></td> 1537 <td><font size="-1">Layer a texture on pixels matching image 1538background color.</font></td> 1539 </tr> 1540 <tr> 1541 <td style="text-align: center;"> 1542 <center><a name="threshold"></a> <font size="-1">threshold</font></center> 1543 </td> 1544 <td><font size="-1">double threshold_</font></td> 1545 <td><font size="-1">Threshold image</font></td> 1546 </tr> 1547 <tr> 1548 <td style="text-align: center;" rowspan="2"> 1549 <center><a name="transform"></a> <font size="-1">transform</font></center> 1550 </td> 1551 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1552&imageGeometry_</font></td> 1553 <td rowspan="2"><font size="-1">Transform image based on image 1554and crop geometries. Crop geometry is optional.</font></td> 1555 </tr> 1556 <tr> 1557 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1558&imageGeometry_, const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1559&cropGeometry_ </font></td> 1560 </tr> 1561 <tr> 1562 <td style="text-align: center;"> 1563 <center><a name="transparent"></a> <font size="-1">transparent</font></center> 1564 </td> 1565 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1566&color_</font></td> 1567 <td><font size="-1">Add matte image to image, setting pixels 1568matching color to transparent.</font></td> 1569 </tr> 1570 <tr> 1571 <td style="text-align: center;"> 1572 <center><a name="trim"></a> <font size="-1">trim</font></center> 1573 </td> 1574 <td><font size="-1">void</font></td> 1575 <td><font size="-1">Trim edges that are the background color from 1576the image.</font></td> 1577 </tr> 1578 <tr> 1579 <td style="text-align: center;"> 1580 <center><a name="unsharpmask"></a> <font size="-1">unsharpmask</font></center> 1581 </td> 1582 <td><font size="-1">double radius_, double sigma_, double 1583amount_, double threshold_</font></td> 1584 <td><font size="-1">Sharpen the image using the unsharp mask 1585algorithm. The <i>radius</i>_ 1586parameter specifies the radius of the Gaussian, in pixels, not 1587counting the center pixel. The <i>sigma</i>_ parameter specifies the 1588standard deviation of the Gaussian, in pixels. The <i>amount</i>_ 1589parameter specifies the percentage of the difference between the 1590original and the blur image that is added back into the original. The <i>threshold</i>_ 1591parameter specifies the threshold in pixels needed to apply the 1592difference amount.</font></td> 1593 </tr> 1594 <tr> 1595 <td style="vertical-align: middle; text-align: center;"><small><a 1596 name="unsharpmaskChannel"></a>unsharpmaskChannel<br> 1597 </small></td> 1598 <td style="vertical-align: middle;"><small>const ChannelType 1599channel_, const double radius_, const double sigma_, const double 1600amount_, const double threshold_<br> 1601 </small></td> 1602 <td style="vertical-align: middle;"><small>Sharpen an image 1603channel using the unsharp mask algorithm. The <span 1604 style="font-style: italic;">channel_</span> parameter specifies the 1605channel to sharpen. </small><font size="-1">The <i>radius</i>_ 1606parameter specifies the radius of the Gaussian, in pixels, not 1607counting the center pixel. The <i>sigma</i>_ parameter specifies the 1608standard deviation of the Gaussian, in pixels. The <i>amount</i>_ 1609parameter specifies the percentage of the difference between the 1610original and the blur image that is added back into the original. The <i>threshold</i>_ 1611parameter specifies the threshold in pixels needed to apply the 1612difference amount.</font></td> 1613 </tr> 1614 <tr> 1615 <td style="text-align: center;"> 1616 <center><a name="wave"></a> <font size="-1">wave</font></center> 1617 </td> 1618 <td><font size="-1">double amplitude_ = 25.0, double wavelength_ 1619= 150.0</font></td> 1620 <td><font size="-1">Alter an image along a sine wave.</font></td> 1621 </tr> 1622 <tr> 1623 <td style="text-align: center;" rowspan="5"> 1624 <center><a name="write"></a> <font size="-1">write</font></center> 1625 </td> 1626 <td><font size="-1">const string &imageSpec_</font></td> 1627 <td><font size="-1">Write image to a file using filename i<i>mageSpec_</i> 1628.</font> <br> 1629 <font size="-1"><b><font color="#ff0000">Caution: </font></b> if 1630an image format is selected which is capable of supporting fewer 1631colors than the original image or quantization has been requested, the 1632original image will be quantized to fewer colors. Use a copy of the 1633original if this is a problem.</font></td> 1634 </tr> 1635 <tr> 1636 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> *blob_</font></td> 1637 <td rowspan="3"><font size="-1">Write image to a in-memory <a 1638 href="http://www.imagemagick.org/Magick++/Blob.html"> BLOB</a> stored in <i>blob_</i>. The <i>magick</i>_ 1639parameter specifies the image format to write (defaults to <a 1640 href="Image++.html#magick">magick</a> ). The depth_ parameter species the image 1641depth (defaults to <a href="Image++.html#depth"> depth</a> ).</font> <br> 1642 <font size="-1"><b><font color="#ff0000">Caution: </font></b> if 1643an image format is selected which is capable of supporting fewer 1644colors than the original image or quantization has been requested, the 1645original image will be quantized to fewer colors. Use a copy of the 1646original if this is a problem.</font></td> 1647 </tr> 1648 <tr> 1649 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> *blob_, 1650std::string &magick_</font></td> 1651 </tr> 1652 <tr> 1653 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> *blob_, 1654std::string &magick_, size_t depth_</font></td> 1655 </tr> 1656 <tr> 1657 <td><font size="-1">const ssize_t x_, const ssize_t y_, const size_t 1658columns_, const size_t rows_, const std::string &map_, 1659const StorageType type_, void *pixels_</font></td> 1660 <td><font size="-1">Write pixel data into a buffer you supply. 1661The data is saved either as char, short int, integer, float or double 1662format in the order specified by the type_ parameter. For example, we 1663want to extract scanline 1 of a 640x480 image as character data in 1664red-green-blue order:</font> 1665 <p><font size="-1"> image.write(0,0,640,1,"RGB",0,pixels);</font> 1666 </p> 1667 <p><font size="-1">The parameters are as follows:</font> <br> 1668 1669 <table border="0" width="100%"> 1670 <tbody> 1671 <tr> 1672 <td><font size="-1">x_</font></td> 1673 <td><font size="-1">Horizontal ordinate of left-most 1674coordinate of region to extract.</font></td> 1675 </tr> 1676 <tr> 1677 <td><font size="-1">y_</font></td> 1678 <td><font size="-1">Vertical ordinate of top-most 1679coordinate of region to extract.</font></td> 1680 </tr> 1681 <tr> 1682 <td><font size="-1">columns_</font></td> 1683 <td><font size="-1">Width in pixels of the region to 1684extract.</font></td> 1685 </tr> 1686 <tr> 1687 <td><font size="-1">rows_</font></td> 1688 <td><font size="-1">Height in pixels of the region to 1689extract.</font></td> 1690 </tr> 1691 <tr> 1692 <td><font size="-1">map_</font></td> 1693 <td><font size="-1">This character string can be any 1694combination or order of R = red, G = green, B = blue, A = alpha, C = 1695cyan, Y = yellow, M = magenta, and K = black. The ordering reflects 1696the order of the pixels in the supplied pixel array.</font></td> 1697 </tr> 1698 <tr> 1699 <td><font size="-1">type_</font></td> 1700 <td><font size="-1">Pixel storage type (CharPixel, 1701ShortPixel, IntegerPixel, FloatPixel, or DoublePixel)</font></td> 1702 </tr> 1703 <tr> 1704 <td><font size="-1">pixels_</font></td> 1705 <td><font size="-1">This array of values contain the pixel 1706components as defined by the map_ and type_ parameters. The length of 1707the arrays must equal the area specified by the width_ and height_ 1708values and type_ parameters.</font></td> 1709 </tr> 1710 </tbody> 1711 </table> 1712 </p> 1713 </td> 1714 </tr> 1715 <tr> 1716 <td style="text-align: center;"> 1717 <center><a name="resize"></a> <font size="-1">resize</font></center> 1718 </td> 1719 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 1720&geometry_</font></td> 1721 <td><font size="-1">Resize image to specified size.</font></td> 1722 </tr> 1723 </tbody> 1724</table></ul> 1725</p> 1726</div> 1727<h2> <a name="Image Attributes"></a> Image Attributes</h2> 1728<div class="doc-section"> 1729Image attributes are set and obtained via methods in Image. Except for 1730methods which accept pointer arguments (e.g. c<tt>hromaBluePrimary)</tt> 1731all methods return attributes by value. 1732<p>Image attributes are easily used. For example, to set the resolution 1733of the TIFF file "file.tiff" to 150 dots-per-inch (DPI) in both the 1734horizontal and vertical directions, you can use the following example 1735code: </p> 1736<pre class="code"> 1737string filename("file.tiff"); 1738Image image; 1739image.read(filename); 1740image.resolutionUnits(PixelsPerInchResolution); 1741image.density(Geometry(150,150)); // could also use image.density("150x150") 1742image.write(filename) 1743</pre> 1744The supported image attributes and the method arguments required to 1745obtain them are shown in the following table: <br> 1746 1747<ul><table border="1"> 1748 <caption>Image Attributes</caption> <tbody> 1749 <tr> 1750 <td> 1751 <center><b>Function</b></center> 1752 </td> 1753 <td> 1754 <center><b>Type</b></center> 1755 </td> 1756 <td> 1757 <center><b>Get Signature</b></center> 1758 </td> 1759 <td> 1760 <center><b>Set Signature</b></center> 1761 </td> 1762 <td> 1763 <center><b>Description</b></center> 1764 </td> 1765 </tr> 1766 <tr> 1767 <td> 1768 <center><a name="adjoin"></a> <font size="-1">adjoin</font></center> 1769 </td> 1770 <td><font size="-1">bool</font></td> 1771 <td><font size="-1">void</font></td> 1772 <td><font size="-1">bool flag_</font></td> 1773 <td><font size="-1">Join images into a single multi-image file.</font></td> 1774 </tr> 1775 <tr> 1776 <td> 1777 <center><a name="antiAlias"></a> <font size="-1">antiAlias</font></center> 1778 </td> 1779 <td><font size="-1">bool</font></td> 1780 <td><font size="-1">void</font></td> 1781 <td><font size="-1">bool flag_</font></td> 1782 <td><font size="-1">Control antialiasing of rendered Postscript 1783and Postscript or TrueType fonts. Enabled by default.</font></td> 1784 </tr> 1785 <tr> 1786 <td> 1787 <center><a name="animationDelay"></a> <font size="-1">animation-</font> 1788 <br> 1789 <font size="-1">Delay</font></center> 1790 </td> 1791 <td><font size="-1">size_t (0 to 65535)</font></td> 1792 <td><font size="-1">void</font></td> 1793 <td><font size="-1">size_t delay_</font></td> 1794 <td><font size="-1">Time in 1/100ths of a second (0 to 65535) 1795which must expire before displaying the next image in an animated 1796sequence. This option is useful for regulating the animation of a 1797sequence of GIF images within Netscape.</font></td> 1798 </tr> 1799 <tr> 1800 <td> 1801 <center><a name="animationIterations"></a> <font size="-1">animation-</font> 1802 <br> 1803 <font size="-1">Iterations</font></center> 1804 </td> 1805 <td><font size="-1">size_t</font></td> 1806 <td><font size="-1">void</font></td> 1807 <td><font size="-1">size_t iterations_</font></td> 1808 <td><font size="-1">Number of iterations to loop an animation 1809(e.g. Netscape loop extension) for.</font></td> 1810 </tr> 1811 <tr> 1812 <td style="vertical-align: middle; text-align: center;"><small><a 1813 name="attribute"></a>attribute<br> 1814 </small></td> 1815 <td style="vertical-align: middle;"><small>string<br> 1816 </small></td> 1817 <td style="vertical-align: top;" valign="top"><small>const 1818std::string name_<br> 1819 </small></td> 1820 <td style="vertical-align: top;" valign="top"><small>const 1821std::string name_, const std::string value_</small></td> 1822 <td style="vertical-align: middle;"><small>An arbitrary named 1823image attribute. Any number of named attributes may be attached to the 1824image. For example, the image comment is a named image attribute with 1825the name "comment". EXIF tags are attached to the image as named 1826attributes. Use the syntax "EXIF:<tag>" to request an EXIF tag 1827similar to "EXIF:DateTime".</small><br> 1828 </td> 1829 </tr> 1830 <tr> 1831 <td> 1832 <center><a name="backgroundColor"></a> <font size="-1">background-</font> 1833 <br> 1834 <font size="-1">Color</font></center> 1835 </td> 1836 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 1837 <td><font size="-1">void</font></td> 1838 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1839&color_</font></td> 1840 <td><font size="-1">Image background color</font></td> 1841 </tr> 1842 <tr> 1843 <td> 1844 <center><a name="backgroundTexture"></a> <font size="-1">background-</font> 1845 <br> 1846 <font size="-1">Texture</font></center> 1847 </td> 1848 <td><font size="-1">string</font></td> 1849 <td><font size="-1">void</font></td> 1850 <td><font size="-1">const string &texture_</font></td> 1851 <td><font size="-1">Image file name to use as the background 1852texture. Does not modify image pixels.</font></td> 1853 </tr> 1854 <tr> 1855 <td> 1856 <center><a name="baseColumns"></a> <font size="-1">baseColumns</font></center> 1857 </td> 1858 <td><font size="-1">size_t</font></td> 1859 <td><font size="-1">void</font></td> 1860 <td bgcolor="#666666"><font size="-1"> </font></td> 1861 <td><font size="-1">Base image width (before transformations)</font></td> 1862 </tr> 1863 <tr> 1864 <td> 1865 <center><a name="baseFilename"></a> <font size="-1">baseFilename</font></center> 1866 </td> 1867 <td><font size="-1">string</font></td> 1868 <td><font size="-1">void</font></td> 1869 <td bgcolor="#666666"><font size="-1"> </font></td> 1870 <td><font size="-1">Base image filename (before transformations)</font></td> 1871 </tr> 1872 <tr> 1873 <td> 1874 <center><a name="baseRows"></a> <font size="-1">baseRows</font></center> 1875 </td> 1876 <td><font size="-1">size_t</font></td> 1877 <td><font size="-1">void</font></td> 1878 <td bgcolor="#666666"><font size="-1"> </font></td> 1879 <td><font size="-1">Base image height (before transformations)</font></td> 1880 </tr> 1881 <tr> 1882 <td> 1883 <center><a name="borderColor"></a> <font size="-1">borderColor</font></center> 1884 </td> 1885 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 1886 <td><font size="-1">void</font></td> 1887 <td><font size="-1"> const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1888&color_</font></td> 1889 <td><font size="-1">Image border color</font></td> 1890 </tr> 1891 <tr> 1892 <td><a name="boundingBox"></a> <font size="-1">boundingBox</font></td> 1893 <td><font size="-1">Geometry</font></td> 1894 <td><font size="-1">void</font></td> 1895 <td bgcolor="#666666"><font size="-1"> </font></td> 1896 <td><font size="-1">Return smallest bounding box enclosing 1897non-border pixels. The current fuzz value is used when discriminating 1898between pixels. This is the crop bounding box used by 1899crop(Geometry(0,0)).</font></td> 1900 </tr> 1901 <tr> 1902 <td> 1903 <center><a name="boxColor"></a> <font size="-1">boxColor</font></center> 1904 </td> 1905 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 1906 <td><font size="-1">void</font></td> 1907 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 1908&boxColor_</font></td> 1909 <td><font size="-1">Base color that annotation text is rendered 1910on.</font></td> 1911 </tr> 1912 <tr> 1913 <td><a name="cacheThreshold"></a> <font size="-1">cacheThreshold</font></td> 1914 <td><font size="-1">size_t</font></td> 1915 <td bgcolor="#666666"><font size="-1"> </font></td> 1916 <td><font size="-1">const size_t</font></td> 1917 <td><font size="-1">Pixel cache threshold in megabytes. Once this 1918threshold is exceeded, all subsequent pixels cache operations are 1919to/from disk. This is a static method and the attribute it sets is 1920shared by all Image objects.</font></td> 1921 </tr> 1922 <tr> 1923 <td style="vertical-align: middle;" valign="middle"><small><a 1924 name="channelDepth"></a>channelDepth<br> 1925 </small></td> 1926 <td style="vertical-align: middle;" valign="middle"><small>size_t 1927<br> 1928 </small></td> 1929 <td style="vertical-align: middle;" valign="middle"><small>const 1930ChannelType channel_<br> 1931 </small></td> 1932 <td style="vertical-align: middle;"><small>const ChannelType 1933channel_, const size_t depth_<br> 1934 </small></td> 1935 <td style="vertical-align: middle;"><small>Channel modulus depth. 1936The channel modulus depth represents the minimum number of bits 1937required 1938to support the channel without loss. Setting the channel's modulus 1939depth 1940modifies the channel (i.e. discards resolution) if the requested 1941modulus 1942depth is less than the current modulus depth, otherwise the channel is 1943not altered. There is no attribute associated with the modulus depth so 1944the current modulus depth is obtained by inspecting the pixels. As a 1945result, the depth returned may be less than the most recently set 1946channel depth. Subsequent image processing may result in increasing the 1947channel depth.<br> 1948 </small></td> 1949 </tr> 1950 <tr> 1951 <td> 1952 <center><a name="chromaBluePrimary"></a> <font size="-1">chroma-</font> 1953 <br> 1954 <font size="-1">BluePrimary</font></center> 1955 </td> 1956 <td><font size="-1">double x & y</font></td> 1957 <td><font size="-1">double *x_, double *y_</font></td> 1958 <td><font size="-1">double x_, double y_</font></td> 1959 <td><font size="-1">Chromaticity blue primary point (e.g. x=0.15, 1960y=0.06)</font></td> 1961 </tr> 1962 <tr> 1963 <td> 1964 <center><a name="chromaGreenPrimary"></a> <font size="-1">chroma-</font> 1965 <br> 1966 <font size="-1">GreenPrimary</font></center> 1967 </td> 1968 <td><font size="-1">double x & y</font></td> 1969 <td><font size="-1">double *x_, double *y_</font></td> 1970 <td><font size="-1">double x_, double y_</font></td> 1971 <td><font size="-1">Chromaticity green primary point (e.g. x=0.3, 1972y=0.6)</font></td> 1973 </tr> 1974 <tr> 1975 <td> 1976 <center><a name="chromaRedPrimary"></a> <font size="-1">chroma-</font> 1977 <br> 1978 <font size="-1">RedPrimary</font></center> 1979 </td> 1980 <td><font size="-1">double x & y</font></td> 1981 <td><font size="-1">double *x_, double *y_</font></td> 1982 <td><font size="-1">double x_, double y_</font></td> 1983 <td><font size="-1">Chromaticity red primary point (e.g. x=0.64, 1984y=0.33)</font></td> 1985 </tr> 1986 <tr> 1987 <td> 1988 <center><a name="chromaWhitePoint"></a> <font size="-1">chroma-</font> 1989 <br> 1990 <font size="-1">WhitePoint</font></center> 1991 </td> 1992 <td><font size="-1">double x & y</font></td> 1993 <td><font size="-1">double*x_, double *y_</font></td> 1994 <td><font size="-1">double x_, double y_</font></td> 1995 <td><font size="-1">Chromaticity white point (e.g. x=0.3127, 1996y=0.329)</font></td> 1997 </tr> 1998 <tr> 1999 <td> 2000 <center><a name="classType"></a> <font size="-1">classType</font></center> 2001 </td> 2002 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ClassType">ClassType</a> 2003 </font></td> 2004 <td><font size="-1">void</font></td> 2005 <td><font size="-1"> <a href="http://www.imagemagick.org/Magick++/Enumerations.html#ClassType">ClassType</a> 2006class_</font></td> 2007 <td><font size="-1">Image storage class. Note that 2008conversion from a DirectClass image to a PseudoClass image may result 2009in a loss of color due to the limited size of the palette (256 or 201065535 colors).</font></td> 2011 </tr> 2012 <tr> 2013 <td> 2014 <center><a name="clipMask"></a> <font size="-1">clipMask</font></center> 2015 </td> 2016 <td><font size="-1">Image</font></td> 2017 <td><font size="-1">void</font></td> 2018 <td><font size="-1">const Image &clipMask_</font></td> 2019 <td><font size="-1">Associate a clip mask image with the current 2020image. The clip mask image must have the same dimensions as the current 2021image or an exception is thrown. Clipping occurs wherever pixels are 2022transparent in the clip mask image. Clipping Pass an invalid image to 2023unset an existing clip mask.</font></td> 2024 </tr> 2025 <tr> 2026 <td> 2027 <center><a name="colorFuzz"></a> <font size="-1">colorFuzz</font></center> 2028 </td> 2029 <td><font size="-1">double</font></td> 2030 <td><font size="-1">void</font></td> 2031 <td><font size="-1">double fuzz_</font></td> 2032 <td><font size="-1">Colors within this distance are considered 2033equal. A number of algorithms search for a target color. By 2034default the color must be exact. Use this option to match colors that 2035are close to the target color in RGB space.</font></td> 2036 </tr> 2037 <tr> 2038 <td> 2039 <center><a name="colorMap"></a> <font size="-1">colorMap</font></center> 2040 </td> 2041 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 2042 <td><font size="-1">size_t index_</font></td> 2043 <td><font size="-1">size_t index_, const <a 2044 href="http://www.imagemagick.org/Magick++/Color.html"> Color</a> &color_</font></td> 2045 <td><font size="-1">Color at colormap index.</font></td> 2046 </tr> 2047 <tr> 2048 <td valign="middle"> 2049 <div align="center"><a name="colorMapSize"></a> <font size="-1">colorMapSize<br> 2050 </font></div> 2051 </td> 2052 <td valign="middle"><font size="-1">size_t<br> 2053 </font></td> 2054 <td valign="middle"><font size="-1">void<br> 2055 </font></td> 2056 <td valign="middle"><font size="-1">size_t entries_<br> 2057 </font></td> 2058 <td valign="middle"><font size="-1">Number of entries in the 2059colormap. Setting the colormap size may extend or truncate the 2060colormap. 2061The maximum number of supported entries is specified by the <i>MaxColormapSize</i>constant, 2062and is dependent on the value of QuantumDepth when ImageMagick is 2063compiled. An exception is thrown if more entries are requested than may 2064be supported. Care should be taken when truncating the colormap to 2065ensure that the image colormap indexes reference valid colormap entries.</font><br> 2066 </td> 2067 </tr> 2068 <tr> 2069 <td> 2070 <center><a name="colorSpace"></a> <font size="-1">colorSpace</font></center> 2071 </td> 2072 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ColorspaceType">ColorspaceType</a> 2073colorSpace_</font></td> 2074 <td><font size="-1">void</font></td> 2075 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ColorspaceType">ColorspaceType</a> 2076colorSpace_</font></td> 2077 <td><font size="-1">The colorspace (e.g. CMYK) used to represent 2078the image pixel colors. Image pixels are always stored as RGB(A) except 2079for the case of CMY(K).</font></td> 2080 </tr> 2081 <tr> 2082 <td> 2083 <center><a name="columns"></a> <font size="-1">columns</font></center> 2084 </td> 2085 <td><font size="-1">size_t</font></td> 2086 <td><font size="-1">void</font></td> 2087 <td bgcolor="#666666"><font size="-1"> </font></td> 2088 <td><font size="-1">Image width</font></td> 2089 </tr> 2090 <tr> 2091 <td> 2092 <center><a name="comment"></a> <font size="-1">comment</font></center> 2093 </td> 2094 <td><font size="-1">string</font></td> 2095 <td><font size="-1">void</font></td> 2096 <td bgcolor="#666666"><font size="-1"> </font></td> 2097 <td><font size="-1">Image comment</font></td> 2098 </tr> 2099 <tr> 2100 <td> 2101 <center><a name="compose"></a> <font size="-1">compose</font></center> 2102 </td> 2103 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#CompositeOperator">CompositeOperator</a> 2104 </font></td> 2105 <td><small><font size="-1"><small>void</small></font></small></td> 2106 <td><small><font size="-1"><small><a 2107 href="http://www.imagemagick.org/Magick++/Enumerations.html#CompositeOperator">CompositeOperator</a> 2108compose_</small></font></small></td> 2109 <td><font size="-1">Composition operator to be used when 2110composition is implicitly used (such as for image flattening).</font></td> 2111 </tr> 2112 <tr> 2113 <td> 2114 <center><a name="compressType"></a> <font size="-1">compress-</font> 2115 <br> 2116 <font size="-1">Type</font></center> 2117 </td> 2118 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#CompressionType">CompressionType</a> 2119 </font></td> 2120 <td><small><font size="-1"><small>void</small></font></small></td> 2121 <td><small><font size="-1"><small><a 2122 href="http://www.imagemagick.org/Magick++/Enumerations.html#CompressionType">CompressionType</a> 2123compressType_</small></font></small></td> 2124 <td><font size="-1">Image compresion type. The default is the 2125compression type of the specified image file.</font></td> 2126 </tr> 2127 <tr> 2128 <td> 2129 <center><a name="debug"></a> <font size="-1">debug</font></center> 2130 </td> 2131 <td><font size="-1">bool</font></td> 2132 <td><small><font size="-1"><small>void</small></font></small></td> 2133 <td><small><font size="-1"><small>bool flag_</small></font></small></td> 2134 <td><font size="-1">Enable printing of internal debug messages 2135from ImageMagick as it executes.</font></td> 2136 </tr> 2137 <tr> 2138 <td style="text-align: center; vertical-align: middle;"><small><a 2139 name="defineValue"></a>defineValue<br> 2140 </small></td> 2141 <td style="vertical-align: middle; text-align: left;"><small>string<br> 2142 </small></td> 2143 <td style="vertical-align: middle;"><small>const std::string 2144&magick_, const std::string &key_<br> 2145 </small></td> 2146 <td style="vertical-align: middle;"><small>const std::string 2147&magick_, const std::string &key_, const std::string 2148&value_<br> 2149 </small></td> 2150 <td style="vertical-align: top;"><small>Set or obtain a 2151definition string to applied when encoding or decoding the specified 2152format. The meanings of the definitions are format specific. The format 2153is designated by the <span style="font-style: italic;">magick_</span> 2154argument, the format-specific key is designated by <span 2155 style="font-style: italic;">key_</span>, and the associated value is 2156specified by <span style="font-style: italic;">value_</span>. See the 2157defineSet() method if the key must be removed entirely.</small><br> 2158 </td> 2159 </tr> 2160 <tr> 2161 <td style="text-align: center; vertical-align: middle;"><small><a 2162 name="defineSet"></a>defineSet<br> 2163 </small></td> 2164 <td style="vertical-align: middle; text-align: left;"><small>bool<br> 2165 </small></td> 2166 <td style="vertical-align: middle;"><small>const std::string 2167&magick_, const std::string &key_<br> 2168 </small></td> 2169 <td style="vertical-align: middle;"><small>const std::string 2170&magick_, const std::string &key_, bool flag_<br> 2171 </small></td> 2172 <td style="vertical-align: middle;"><small>Set or obtain a 2173definition flag to applied when encoding or decoding the specified 2174format.</small><small>. Similar to the defineValue() method except that 2175passing the <span style="font-style: italic;">flag_</span> value 2176'true' 2177creates a value-less define with that format and key. Passing the <span 2178 style="font-style: italic;">f</span><span style="font-style: italic;">lag_</span> 2179value 'false' removes any existing matching definition. The method 2180returns 'true' if a matching key exists, and 'false' if no matching key 2181exists.<br> 2182 </small></td> 2183 </tr> 2184 <tr> 2185 <td> 2186 <center><a name="density"></a> <font size="-1">density</font></center> 2187 </td> 2188 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 2189(default 72x72)</font></td> 2190 <td><font size="-1">void</font></td> 2191 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 2192&density_</font></td> 2193 <td><font size="-1">Vertical and horizontal resolution in pixels 2194of the image. This option specifies an image density when decoding a 2195Postscript or Portable Document page. Often used with <i>psPageSize</i>.</font></td> 2196 </tr> 2197 <tr> 2198 <td> 2199 <center><a name="depth"></a> <font size="-1">depth</font></center> 2200 </td> 2201 <td><font size="-1"> size_t (8-32)</font></td> 2202 <td><font size="-1">void</font></td> 2203 <td><font size="-1">size_t depth_</font></td> 2204 <td><font size="-1">Image depth. Used to specify the bit depth 2205when reading or writing raw images or when the output format 2206supports multiple depths. Defaults to the quantum depth that 2207ImageMagick is compiled with.</font></td> 2208 </tr> 2209 <tr> 2210 <td> 2211 <center><a name="endian"></a> <font size="-1">endian</font></center> 2212 </td> 2213 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#EndianType">EndianType</a> 2214 </font></td> 2215 <td><font size="-1">void</font></td> 2216 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#EndianType">EndianType</a> 2217endian_</font></td> 2218 <td><font size="-1">Specify (or obtain) endian option for formats 2219which support it.</font></td> 2220 </tr> 2221 <tr> 2222 <td> 2223 <center><a name="directory"></a> <font size="-1">directory</font></center> 2224 </td> 2225 <td><font size="-1">string</font></td> 2226 <td><font size="-1">void</font></td> 2227 <td><font size="-1"> </font></td> 2228 <td><font size="-1">Tile names from within an image montage</font></td> 2229 </tr> 2230 <tr> 2231 <td> 2232 <center><a name="file"></a> <font size="-1">file</font></center> 2233 </td> 2234 <td><font size="-1">FILE *</font></td> 2235 <td><font size="-1">FILE *</font></td> 2236 <td><font size="-1">FILE *file_</font></td> 2237 <td><font size="-1">Image file descriptor.</font></td> 2238 </tr> 2239 <tr> 2240 <td> 2241 <center><a name="fileName"></a> <font size="-1">fileName</font></center> 2242 </td> 2243 <td><font size="-1">string</font></td> 2244 <td><font size="-1">void</font></td> 2245 <td><font size="-1">const string &fileName_</font></td> 2246 <td><font size="-1">Image file name.</font></td> 2247 </tr> 2248 <tr> 2249 <td> 2250 <center><a name="fileSize"></a> <font size="-1">fileSize</font></center> 2251 </td> 2252 <td><font size="-1">off_t</font></td> 2253 <td><font size="-1">void</font></td> 2254 <td bgcolor="#666666"><font size="-1"> </font></td> 2255 <td><font size="-1">Number of bytes of the image on disk</font></td> 2256 </tr> 2257 <tr> 2258 <td> 2259 <center><a name="fillColor"></a> <font size="-1">fillColor</font></center> 2260 </td> 2261 <td><font size="-1">Color</font></td> 2262 <td><font size="-1">void</font></td> 2263 <td><font size="-1">const Color &fillColor_</font></td> 2264 <td><font size="-1">Color to use when filling drawn objects</font></td> 2265 </tr> 2266 <tr> 2267 <td> 2268 <center><a name="fillPattern"></a> <font size="-1">fillPattern</font></center> 2269 </td> 2270 <td><font size="-1">Image</font></td> 2271 <td><font size="-1">void</font></td> 2272 <td><font size="-1">const Image &fillPattern_</font></td> 2273 <td><font size="-1">Pattern image to use when filling drawn 2274objects.</font></td> 2275 </tr> 2276 <tr> 2277 <td> 2278 <center><a name="fillRule"></a> <font size="-1">fillRule</font></center> 2279 </td> 2280 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#FillRule">FillRule</a> 2281 </font></td> 2282 <td><font size="-1">void</font></td> 2283 <td><font size="-1">const Magick::FillRule &fillRule_</font></td> 2284 <td><font size="-1">Rule to use when filling drawn objects.</font></td> 2285 </tr> 2286 <tr> 2287 <td> 2288 <center><a name="filterType"></a> <font size="-1">filterType</font></center> 2289 </td> 2290 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#FilterTypes">FilterTypes</a> 2291 </font></td> 2292 <td><font size="-1">void</font></td> 2293 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#FilterTypes">FilterTypes</a> 2294filterType_</font></td> 2295 <td><font size="-1">Filter to use when resizing image. The 2296reduction filter employed has a significant effect on the time required 2297to resize an image and the resulting quality. The default filter is <i>Lanczos</i> 2298which has been shown to produce high quality results when reducing most 2299images.</font></td> 2300 </tr> 2301 <tr> 2302 <td> 2303 <center><a name="font"></a> <font size="-1">font</font></center> 2304 </td> 2305 <td><font size="-1">string</font></td> 2306 <td><font size="-1">void</font></td> 2307 <td><font size="-1">const string &font_</font></td> 2308 <td><font size="-1">Text rendering font. If the font is a fully 2309qualified X server font name, the font is obtained from an X 2310server. To use a TrueType font, precede the TrueType filename with an 2311@. Otherwise, specify a Postscript font name (e.g. 2312"helvetica").</font></td> 2313 </tr> 2314 <tr> 2315 <td> 2316 <center><a name="fontPointsize"></a> <font size="-1">fontPointsize</font></center> 2317 </td> 2318 <td><font size="-1">size_t</font></td> 2319 <td><font size="-1">void</font></td> 2320 <td><font size="-1">size_t pointSize_</font></td> 2321 <td><font size="-1">Text rendering font point size</font></td> 2322 </tr> 2323 <tr> 2324 <td> 2325 <center><a name="fontTypeMetrics"></a> <font size="-1">fontTypeMetrics</font></center> 2326 </td> 2327 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/TypeMetric.html">TypeMetric</a> </font></td> 2328 <td><font size="-1">const std::string &text_, <a 2329 href="http://www.imagemagick.org/Magick++/TypeMetric.html"> TypeMetric</a> *metrics</font></td> 2330 <td bgcolor="#666666"><font size="-1"> </font></td> 2331 <td><font size="-1">Update metrics with font type metrics using 2332specified <i>text</i>, and current <a href="Image++.html#font">font</a> and <a 2333 href="Image++.html#fontPointsize">fontPointSize</a> settings.</font></td> 2334 </tr> 2335 <tr> 2336 <td> 2337 <center><a name="format"></a> <font size="-1">format</font></center> 2338 </td> 2339 <td><font size="-1">string</font></td> 2340 <td><font size="-1">void</font></td> 2341 <td bgcolor="#666666"><font size="-1"> </font></td> 2342 <td><font size="-1">Long form image format description.</font></td> 2343 </tr> 2344 <tr> 2345 <td> 2346 <center><a name="gamma"></a> <font size="-1">gamma</font></center> 2347 </td> 2348 <td><font size="-1">double (typical range 0.8 to 2.3)</font></td> 2349 <td><font size="-1">void</font></td> 2350 <td bgcolor="#666666"><font size="-1"> </font></td> 2351 <td><font size="-1">Gamma level of the image. The same color 2352image displayed on two different workstations may 2353look different due to differences in the display monitor. 2354Use gamma correction to adjust for this 2355color difference.</font></td> 2356 </tr> 2357 <tr> 2358 <td> 2359 <center><a name="geometry"></a> <font size="-1">geometry</font></center> 2360 </td> 2361 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> </font></td> 2362 <td><font size="-1">void</font></td> 2363 <td bgcolor="#666666"><font size="-1"> </font></td> 2364 <td><font size="-1">Preferred size of the image when encoding.</font></td> 2365 </tr> 2366 <tr> 2367 <td> 2368 <center><a name="gifDisposeMethod"></a> <font size="-1">gifDispose-</font> 2369 <br> 2370 <font size="-1">Method</font></center> 2371 </td> 2372 <td><font size="-1">size_t</font> <br> 2373 <font size="-1">{ 0 = Disposal not specified,</font> <br> 2374 <font size="-1">1 = Do not dispose of graphic,</font> <br> 2375 <font size="-1">3 = Overwrite graphic with background color,</font> 2376 <br> 2377 <font size="-1">4 = Overwrite graphic with previous graphic. }</font></td> 2378 <td><font size="-1">void</font></td> 2379 <td><font size="-1">size_t disposeMethod_</font></td> 2380 <td><font size="-1">GIF disposal method. This option is used to 2381control how successive frames are rendered (how the preceding frame is 2382disposed of) when creating a GIF animation.</font></td> 2383 </tr> 2384 <tr> 2385 <td> 2386 <center><a name="iccColorProfile"></a> <font size="-1">iccColorProfile</font></center> 2387 </td> 2388 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> </font></td> 2389 <td><font size="-1">void</font></td> 2390 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> 2391&colorProfile_</font></td> 2392 <td><font size="-1">ICC color profile. Supplied via a <a 2393 href="http://www.imagemagick.org/Magick++/Blob.html"> Blob</a> since Magick++/ and ImageMagick do not 2394currently support formating this data structure directly. 2395Specifications are available from the <a href="http://www.color.org/"> 2396International Color Consortium</a> for the format of ICC color profiles.</font></td> 2397 </tr> 2398 <tr> 2399 <td> 2400 <center><a name="interlaceType"></a> <font size="-1">interlace-</font> 2401 <br> 2402 <font size="-1">Type</font></center> 2403 </td> 2404 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#InterlaceType">InterlaceType</a> 2405 </font></td> 2406 <td><font size="-1">void</font></td> 2407 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#InterlaceType">InterlaceType</a> 2408interlace_</font></td> 2409 <td><font size="-1">The type of interlacing scheme (default <i>NoInterlace</i> 2410). This option is used to specify the type of interlacing 2411scheme for raw image formats such as RGB or YUV. <i>NoInterlace</i> 2412means do not interlace, <i>LineInterlace</i> uses scanline 2413interlacing, and <i>PlaneInterlace</i> uses plane interlacing. <i> 2414PartitionInterlace</i> is like <i>PlaneInterlace</i> except the 2415different planes are saved to individual files (e.g. 2416image.R, image.G, and image.B). Use <i>LineInterlace</i> or <i> 2417PlaneInterlace</i> to create an interlaced GIF or progressive JPEG 2418image.</font></td> 2419 </tr> 2420 <tr> 2421 <td> 2422 <center><a name="iptcProfile"></a> <font size="-1">iptcProfile</font></center> 2423 </td> 2424 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> </font></td> 2425 <td><font size="-1">void</font></td> 2426 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Blob.html">Blob</a> & 2427iptcProfile_</font></td> 2428 <td><font size="-1">IPTC profile. Supplied via a <a 2429 href="http://www.imagemagick.org/Magick++/Blob.html"> Blob</a> since Magick++ and ImageMagick do not 2430currently support formating this data structure directly. 2431Specifications are available from the <a href="http://www.iptc.org/"> 2432International Press Telecommunications Council</a> for IPTC profiles.</font></td> 2433 </tr> 2434 <tr> 2435 <td> 2436 <center><a name="label"></a> <font size="-1">label</font></center> 2437 </td> 2438 <td><font size="-1">string</font></td> 2439 <td><font size="-1">void</font></td> 2440 <td><font size="-1">const string &label_</font></td> 2441 <td><font size="-1">Image label</font></td> 2442 </tr> 2443 <tr> 2444 <td> 2445 <center><a name="magick"></a> <font size="-1">magick</font></center> 2446 </td> 2447 <td><font size="-1">string</font></td> 2448 <td><font size="-1">void</font></td> 2449 <td><font size="-1"> const string &magick_</font></td> 2450 <td><font size="-1">Get image format (e.g. "GIF")</font></td> 2451 </tr> 2452 <tr> 2453 <td> 2454 <center><a name="matte"></a> <font size="-1">matte</font></center> 2455 </td> 2456 <td><font size="-1">bool</font></td> 2457 <td><font size="-1">void</font></td> 2458 <td><font size="-1">bool matteFlag_</font></td> 2459 <td><font size="-1">True if the image has transparency. If set 2460True, store matte channel if the image has one otherwise create 2461an opaque one.</font></td> 2462 </tr> 2463 <tr> 2464 <td> 2465 <center><a name="matteColor"></a> <font size="-1">matteColor</font></center> 2466 </td> 2467 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 2468 <td><font size="-1">void</font></td> 2469 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> 2470&matteColor_</font></td> 2471 <td><font size="-1">Image matte (frame) color</font></td> 2472 </tr> 2473 <tr> 2474 <td> 2475 <center><a name="meanErrorPerPixel"></a> <font size="-1">meanError-</font> 2476 <br> 2477 <font size="-1">PerPixel</font></center> 2478 </td> 2479 <td><font size="-1">double</font></td> 2480 <td><font size="-1">void</font></td> 2481 <td bgcolor="#666666"><font size="-1"> </font></td> 2482 <td><font size="-1">The mean error per pixel computed when an 2483image is color reduced. This parameter is only valid if verbose is set 2484to true and the image has just been quantized.</font></td> 2485 </tr> 2486 <tr> 2487 <td style="text-align: center; vertical-align: middle;"><font 2488 size="-1"><a name="modulusDepth"></a>modulusDepth<br> 2489 </font></td> 2490 <td style="text-align: left; vertical-align: middle;"><small>size_t 2491<br> 2492 </small></td> 2493 <td style="text-align: left; vertical-align: middle;"><small><font 2494 size="-1"><small>void<br> 2495 </small></font></small></td> 2496 <td style="text-align: left; vertical-align: middle;"><small>size_t 2497depth_<br> 2498 </small></td> 2499 <td style="text-align: left; vertical-align: middle;"><small>Image 2500modulus depth (minimum number of bits required to support 2501red/green/blue components without loss of accuracy). The pixel modulus 2502depth may be decreased by supplying a value which is less than the 2503current value, updating the pixels (reducing accuracy) to the new 2504depth. 2505The pixel modulus depth can not be increased over the current value 2506using this method.<br> 2507 </small></td> 2508 </tr> 2509 <tr> 2510 <td> 2511 <center><a name="monochrome"></a> <font size="-1">monochrome</font></center> 2512 </td> 2513 <td><font size="-1">bool</font></td> 2514 <td><font size="-1">void</font></td> 2515 <td><font size="-1">bool flag_</font></td> 2516 <td><font size="-1">Transform the image to black and white</font></td> 2517 </tr> 2518 <tr> 2519 <td> 2520 <center><a name="montageGeometry"></a> <font size="-1">montage-</font> 2521 <br> 2522 <font size="-1">Geometry</font></center> 2523 </td> 2524 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> </font></td> 2525 <td><font size="-1">void</font></td> 2526 <td bgcolor="#666666"><font size="-1"> </font></td> 2527 <td><font size="-1">Tile size and offset within an image montage. 2528Only valid for montage images.</font></td> 2529 </tr> 2530 <tr> 2531 <td> 2532 <center><a name="normalizedMaxError"></a> <font size="-1">normalized-</font> 2533 <br> 2534 <font size="-1">MaxError</font></center> 2535 </td> 2536 <td><font size="-1">double</font></td> 2537 <td><font size="-1">void</font></td> 2538 <td bgcolor="#666666"><font size="-1"> </font></td> 2539 <td><font size="-1">The normalized max error per pixel computed 2540when an image is color reduced. This parameter is only valid if verbose 2541is set to true and the image has just been quantized.</font></td> 2542 </tr> 2543 <tr> 2544 <td> 2545 <center><a name="normalizedMeanError"></a> <font size="-1">normalized-</font> 2546 <br> 2547 <font size="-1">MeanError</font></center> 2548 </td> 2549 <td><font size="-1">double</font></td> 2550 <td><font size="-1">void</font></td> 2551 <td bgcolor="#666666"><font size="-1"> </font></td> 2552 <td><font size="-1">The normalized mean error per pixel computed 2553when an image is color reduced. This parameter is only valid if verbose 2554is set to true and the image has just been quantized.</font></td> 2555 </tr> 2556 <tr> 2557 <td style="text-align: center; vertical-align: middle;"><small><a 2558 name="orientation"></a>orientation<br> 2559 </small></td> 2560 <td style="vertical-align: middle;"><small><a 2561 href="http://www.imagemagick.org/Magick++/Enumerations.html#OrientationType">OrientationType</a></small></td> 2562 <td style="vertical-align: top;"><small>void</small><br> 2563 </td> 2564 <td style="vertical-align: middle;"><small><a 2565 href="http://www.imagemagick.org/Magick++/Enumerations.html#OrientationType">OrientationType</a> 2566orientation_</small></td> 2567 <td style="vertical-align: top;"><small>Image orientation. 2568 Supported by some file formats such as DPX and TIFF. Useful for 2569turning the right way up.<br> 2570 </small></td> 2571 </tr> 2572 <tr> 2573 <td> 2574 <center><a name="packets"></a> <font size="-1">packets</font></center> 2575 </td> 2576 <td><font size="-1">size_t</font></td> 2577 <td><font size="-1">void</font></td> 2578 <td bgcolor="#666666"><font size="-1"> </font></td> 2579 <td><font size="-1">The number of runlength-encoded packets in</font> 2580 <br> 2581 <font size="-1">the image</font></td> 2582 </tr> 2583 <tr> 2584 <td> 2585 <center><a name="packetSize"></a> <font size="-1">packetSize</font></center> 2586 </td> 2587 <td><font size="-1">size_t</font></td> 2588 <td><font size="-1">void</font></td> 2589 <td bgcolor="#666666"><font size="-1"> </font></td> 2590 <td><font size="-1">The number of bytes in each pixel packet</font></td> 2591 </tr> 2592 <tr> 2593 <td> 2594 <center><a name="page"></a> <font size="-1">page</font></center> 2595 </td> 2596 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Geometry.html#PostscriptPageSize">Geometry</a> 2597 </font></td> 2598 <td><font size="-1">void</font></td> 2599 <td><font size="-1">const <a 2600 href="http://www.imagemagick.org/Magick++/Geometry.html#PostscriptPageSize"> Geometry</a> &pageSize_</font></td> 2601 <td><font size="-1">Preferred size and location of an image 2602canvas.</font> 2603 <p><font size="-1">Use this option to specify the dimensions 2604and position of the Postscript page in dots per inch or a TEXT page in 2605pixels. This option is typically used in concert with <i><a 2606 href="Image++.html#density"> density</a> </i>.</font> </p> 2607 <p><font size="-1">Page may also be used to position a GIF 2608image (such as for a scene in an animation)</font></p> 2609 </td> 2610 </tr> 2611 <tr> 2612 <td> 2613 <center><a name="pixelColor"></a> <font size="-1">pixelColor</font></center> 2614 </td> 2615 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Color.html">Color</a> </font></td> 2616 <td><font size="-1">ssize_t x_, ssize_t y_</font></td> 2617 <td><font size="-1">ssize_t x_, ssize_t y_, const <a 2618 href="http://www.imagemagick.org/Magick++/Color.html"> Color</a> &color_</font></td> 2619 <td><font size="-1">Get/set pixel color at location x & y.</font></td> 2620 </tr> 2621 <tr> 2622 <td valign="top"> 2623 <div align="center"><a name="profile"></a> <small>profile</small><br> 2624 </div> 2625 </td> 2626 <td valign="top"><a href="http://www.imagemagick.org/Magick++/Blob.html"><small> Blob</small><small><br> 2627 </small></a> </td> 2628 <td valign="top"><small>const std::string name_</small><small><br> 2629 </small></td> 2630 <td valign="top"><small>const std::string name_, const Blob 2631&colorProfile_</small><small><br> 2632 </small></td> 2633 <td valign="top"><small>Get/set/remove </small><small> a named 2634profile</small><small>. Valid names include </small><small>"*", 2635"8BIM", "ICM", "IPTC", or a user/format-defined profile name. </small><br> 2636 </td> 2637 </tr> 2638 <tr> 2639 <td> 2640 <center><a name="quality"></a> <font size="-1">quality</font></center> 2641 </td> 2642 <td><font size="-1">size_t (0 to 100)</font></td> 2643 <td><font size="-1">void</font></td> 2644 <td><font size="-1">size_t quality_</font></td> 2645 <td><font size="-1">JPEG/MIFF/PNG compression level (default 75).</font></td> 2646 </tr> 2647 <tr> 2648 <td> 2649 <center><a name="quantizeColors"></a> <font size="-1">quantize-</font> 2650 <br> 2651 <font size="-1">Colors</font></center> 2652 </td> 2653 <td><font size="-1">size_t</font></td> 2654 <td><font size="-1">void</font></td> 2655 <td><font size="-1">size_t colors_</font></td> 2656 <td><font size="-1">Preferred number of colors in the image. The 2657actual number of colors in the image may be less than your request, but 2658never more. Images with less unique colors than specified with this 2659option will have any duplicate or unused colors removed.</font></td> 2660 </tr> 2661 <tr> 2662 <td> 2663 <center><a name="quantizeColorSpace"></a> <font size="-1">quantize-</font> 2664 <br> 2665 <font size="-1">ColorSpace</font></center> 2666 </td> 2667 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ColorspaceType">ColorspaceType</a> 2668 </font></td> 2669 <td><font size="-1">void</font></td> 2670 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ColorspaceType">ColorspaceType</a> 2671colorSpace_</font></td> 2672 <td><font size="-1">Colorspace to quantize colors in (default 2673RGB). Empirical evidence suggests that distances in color spaces such 2674as YUV or YIQ correspond to perceptual color differences more closely 2675than do distances in RGB space. These color spaces may give better 2676results when color reducing an image.</font></td> 2677 </tr> 2678 <tr> 2679 <td> 2680 <center><a name="quantizeDither"></a> <font size="-1">quantize-</font> 2681 <br> 2682 <font size="-1">Dither</font></center> 2683 </td> 2684 <td><font size="-1">bool</font></td> 2685 <td><font size="-1">void</font></td> 2686 <td><font size="-1">bool flag_</font></td> 2687 <td><font size="-1">Apply Floyd/Steinberg error diffusion to the 2688image. The basic strategy of dithering is to trade 2689intensity 2690resolution for spatial resolution by 2691averaging the intensities of several 2692neighboring pixels. Images which suffer from 2693severe contouring when reducing colors can be 2694improved with this option. The quantizeColors or monochrome option must 2695be set for this option to take effect.</font></td> 2696 </tr> 2697 <tr> 2698 <td> 2699 <center><a name="quantizeTreeDepth"></a> <font size="-1">quantize-</font> 2700 <br> 2701 <font size="-1">TreeDepth</font></center> 2702 </td> 2703 <td><font size="-1">size_t </font></td> 2704 <td><font size="-1">void</font></td> 2705 <td><font size="-1">size_t treeDepth_</font></td> 2706 <td><font size="-1">Depth of the quantization color 2707classification tree. Values of 0 or 1 allow selection of the optimal 2708tree depth for the color reduction algorithm. Values between 2 and 8 2709may be used to manually adjust the tree depth.</font></td> 2710 </tr> 2711 <tr> 2712 <td> 2713 <center><a name="renderingIntent"></a> <font size="-1">rendering-</font> 2714 <br> 2715 <font size="-1">Intent</font></center> 2716 </td> 2717 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#RenderingIntent">RenderingIntent</a> 2718 </font></td> 2719 <td><font size="-1">void</font></td> 2720 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#RenderingIntent">RenderingIntent</a> 2721render_</font></td> 2722 <td><font size="-1">The type of rendering intent</font></td> 2723 </tr> 2724 <tr> 2725 <td> 2726 <center><a name="resolutionUnits"></a> <font size="-1">resolution-</font> 2727 <br> 2728 <font size="-1">Units</font></center> 2729 </td> 2730 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ResolutionType">ResolutionType</a> 2731 </font></td> 2732 <td><font size="-1">void</font></td> 2733 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ResolutionType">ResolutionType</a> 2734units_</font></td> 2735 <td><font size="-1">Units of image resolution</font></td> 2736 </tr> 2737 <tr> 2738 <td> 2739 <center><a name="rows"></a> <font size="-1">rows</font></center> 2740 </td> 2741 <td><font size="-1">size_t</font></td> 2742 <td><font size="-1">void</font></td> 2743 <td bgcolor="#666666"><font size="-1"> </font></td> 2744 <td><font size="-1">The number of pixel rows in the image</font></td> 2745 </tr> 2746 <tr> 2747 <td> 2748 <center><a name="scene"></a> <font size="-1">scene</font></center> 2749 </td> 2750 <td><font size="-1">size_t</font></td> 2751 <td><font size="-1">void</font></td> 2752 <td><font size="-1">size_t scene_</font></td> 2753 <td><font size="-1">Image scene number</font></td> 2754 </tr> 2755 <tr> 2756 <td> 2757 <center><a name="signature"></a> <font size="-1">signature</font></center> 2758 </td> 2759 <td><font size="-1">string</font></td> 2760 <td><font size="-1">bool force_ = false</font></td> 2761 <td bgcolor="#666666"><font size="-1"> </font></td> 2762 <td><font size="-1">Image MD5 signature. Set force_ to 'true' to 2763force re-computation of signature.</font></td> 2764 </tr> 2765 <tr> 2766 <td> 2767 <center><a name="size"></a> <font size="-1">size</font></center> 2768 </td> 2769 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> </font></td> 2770 <td><font size="-1">void</font></td> 2771 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/Geometry.html">Geometry</a> 2772&geometry_</font></td> 2773 <td><font size="-1">Width and height of a raw image (an image 2774which does not support width and height information). Size may 2775also be used to affect the image size read from a multi-resolution 2776format (e.g. Photo CD, JBIG, or JPEG.</font></td> 2777 </tr> 2778 <tr> 2779 <td style="text-align: center;"> 2780 <center><a name="strip"></a> <font size="-1">strip</font></center> 2781 </td> 2782 <td><font size="-1">void</font></td> 2783 <td><font size="-1">strips an image of all profiles and comments.</font></td> 2784 </tr> 2785 <tr> 2786 <td> 2787 <center><a name="strokeAntiAlias"></a> <font size="-1">strokeAntiAlias</font></center> 2788 </td> 2789 <td><font size="-1">bool</font></td> 2790 <td><font size="-1">void</font></td> 2791 <td><font size="-1">bool flag_</font></td> 2792 <td><font size="-1">Enable or disable anti-aliasing when drawing 2793object outlines.</font></td> 2794 </tr> 2795 <tr> 2796 <td> 2797 <center><a name="strokeColor"></a> <font size="-1">strokeColor</font></center> 2798 </td> 2799 <td><font size="-1">Color</font></td> 2800 <td><font size="-1">void</font></td> 2801 <td><font size="-1">const Color &strokeColor_</font></td> 2802 <td><font size="-1">Color to use when drawing object outlines</font></td> 2803 </tr> 2804 <tr> 2805 <td> 2806 <center><a name="strokeDashOffset"></a> <font size="-1">strokeDashOffset</font></center> 2807 </td> 2808 <td><font size="-1">size_t</font></td> 2809 <td><font size="-1">void</font></td> 2810 <td><font size="-1">double strokeDashOffset_</font></td> 2811 <td><font size="-1">While drawing using a dash pattern, specify 2812distance into the dash pattern to start the dash (default 0).</font></td> 2813 </tr> 2814 <tr> 2815 <td> 2816 <center><a name="strokeDashArray"></a> <font size="-1">strokeDashArray</font></center> 2817 </td> 2818 <td><font size="-1">const double*</font></td> 2819 <td><font size="-1">void</font></td> 2820 <td><font size="-1">const double* strokeDashArray_</font></td> 2821 <td><font size="-1">Specify the pattern of dashes and gaps used 2822to stroke paths. The strokeDashArray represents a zero-terminated 2823array of numbers that specify the lengths (in pixels) of alternating 2824dashes and gaps in user units. If an odd number of values is provided, 2825then the list of values is repeated to yield an even number of 2826values. A typical strokeDashArray_ array might contain the 2827members 5 3 2 0, where the zero value indicates the end of the pattern 2828array.</font></td> 2829 </tr> 2830 <tr> 2831 <td> 2832 <center><a name="strokeLineCap"></a> <font size="-1">strokeLineCap</font></center> 2833 </td> 2834 <td><font size="-1">LineCap</font></td> 2835 <td><font size="-1">void</font></td> 2836 <td><font size="-1">LineCap lineCap_</font></td> 2837 <td><font size="-1">Specify the shape to be used at the corners 2838of paths (or other vector shapes) when they are stroked. Values of 2839LineJoin are UndefinedJoin, MiterJoin, RoundJoin, and BevelJoin.</font></td> 2840 </tr> 2841 <tr> 2842 <td> 2843 <center><a name="strokeLineJoin"></a> <font size="-1">strokeLineJoin</font></center> 2844 </td> 2845 <td><font size="-1">LineJoin</font></td> 2846 <td><font size="-1">void</font></td> 2847 <td><font size="-1">LineJoin lineJoin_</font></td> 2848 <td><font size="-1">Specify the shape to be used at the corners 2849of paths (or other vector shapes) when they are stroked. Values of 2850LineJoin are UndefinedJoin, MiterJoin, RoundJoin, and BevelJoin.</font></td> 2851 </tr> 2852 <tr> 2853 <td> 2854 <center><a name="strokeMiterLimit"></a> <font size="-1">strokeMiterLimit</font></center> 2855 </td> 2856 <td><font size="-1">size_t</font></td> 2857 <td><font size="-1">void</font></td> 2858 <td><font size="-1">size_t miterLimit_</font></td> 2859 <td><font size="-1">Specify miter limit. When two line segments 2860meet at a sharp angle and miter joins have been specified for 2861'lineJoin', it is possible for the miter to extend far beyond the 2862thickness of the line stroking the path. The miterLimit' imposes a 2863limit on the ratio of the miter length to the 'lineWidth'. The default 2864value of this parameter is 4.</font></td> 2865 </tr> 2866 <tr> 2867 <td> 2868 <center><a name="strokeWidth"></a> <font size="-1">strokeWidth</font></center> 2869 </td> 2870 <td><font size="-1">double</font></td> 2871 <td><font size="-1">void</font></td> 2872 <td><font size="-1">double strokeWidth_</font></td> 2873 <td><font size="-1">Stroke width for use when drawing vector 2874objects (default one)</font></td> 2875 </tr> 2876 <tr> 2877 <td> 2878 <center><a name="strokePattern"></a> <font size="-1">strokePattern</font></center> 2879 </td> 2880 <td><font size="-1">Image</font></td> 2881 <td><font size="-1">void</font></td> 2882 <td><font size="-1">const Image &strokePattern_</font></td> 2883 <td><font size="-1">Pattern image to use while drawing object 2884stroke (outlines).</font></td> 2885 </tr> 2886 <tr> 2887 <td> 2888 <center><a name="subImage"></a> <font size="-1">subImage</font></center> 2889 </td> 2890 <td><font size="-1">size_t</font></td> 2891 <td><font size="-1">void</font></td> 2892 <td><font size="-1">size_t subImage_</font></td> 2893 <td><font size="-1">Subimage of an image sequence</font></td> 2894 </tr> 2895 <tr> 2896 <td> 2897 <center><a name="subRange"></a> <font size="-1">subRange</font></center> 2898 </td> 2899 <td><font size="-1">size_t</font></td> 2900 <td><font size="-1">void</font></td> 2901 <td><font size="-1">size_t subRange_</font></td> 2902 <td><font size="-1">Number of images relative to the base image</font></td> 2903 </tr> 2904 <tr> 2905 <td valign="middle"> 2906 <div align="center"><a name="textEncoding"></a> <small>textEncoding</small><br> 2907 </div> 2908 </td> 2909 <td valign="middle"><small>string</small><small><br> 2910 </small></td> 2911 <td valign="middle"><small>void</small><small><br> 2912 </small></td> 2913 <td valign="middle"><small>const std::string &encoding_</small><small><br> 2914 </small></td> 2915 <td valign="top"><small>Specify the code set to use for text 2916annotations. The only character encoding which may be specified at 2917this time is "UTF-8" for representing </small><small><a 2918 href="http://www.unicode.org/"> Unicode </a> </small><small>as a 2919sequence of bytes. Specify an empty string to use the default ASCII 2920encoding. Successful text annotation using Unicode may require fonts 2921designed to support Unicode.</small><br> 2922 </td> 2923 </tr> 2924 <tr> 2925 <td> 2926 <center><a name="tileName"></a> <font size="-1">tileName</font></center> 2927 </td> 2928 <td><font size="-1">string</font></td> 2929 <td><font size="-1">void</font></td> 2930 <td><font size="-1">const string &tileName_</font></td> 2931 <td><font size="-1">Tile name</font></td> 2932 </tr> 2933 <tr> 2934 <td> 2935 <center><a name="totalColors"></a> <font size="-1">totalColors</font></center> 2936 </td> 2937 <td><font size="-1">size_t</font></td> 2938 <td><font size="-1">void</font></td> 2939 <td bgcolor="#666666"><font size="-1"> </font></td> 2940 <td><font size="-1">Number of colors in the image</font></td> 2941 </tr> 2942 <tr> 2943 <td> 2944 <center><a name="type"></a> <font size="-1">type</font></center> 2945 </td> 2946 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#ImageType">ImageType</a> 2947 </font></td> 2948 <td><font size="-1">void</font></td> 2949 <td bgcolor="#ffffff"><font size="-1"><a 2950 href="http://www.imagemagick.org/Magick++/Enumerations.html#ImageType"> ImageType</a> </font></td> 2951 <td><font size="-1">Image type.</font></td> 2952 </tr> 2953 <tr> 2954 <td> 2955 <center><a name="verbose"></a> <font size="-1">verbose</font></center> 2956 </td> 2957 <td><font size="-1">bool</font></td> 2958 <td><font size="-1">void</font></td> 2959 <td><font size="-1">bool verboseFlag_</font></td> 2960 <td><font size="-1">Print detailed information about the image</font></td> 2961 </tr> 2962 <tr> 2963 <td> 2964 <center><a name="view"></a> <font size="-1">view</font></center> 2965 </td> 2966 <td><font size="-1">string</font></td> 2967 <td><font size="-1">void</font></td> 2968 <td><font size="-1">const string &view_</font></td> 2969 <td><font size="-1">FlashPix viewing parameters.</font></td> 2970 </tr> 2971 <tr> 2972 <td> 2973 <center><a name="virtualPixelMethod"></a> <font size="-1">virtualPixelMethod</font></center> 2974 </td> 2975 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#VirtualPixelMethod">VirtualPixelMethod</a> 2976 </font></td> 2977 <td><small><font size="-1"><small>void</small></font></small></td> 2978 <td><small><font size="-1"><small><a 2979 href="http://www.imagemagick.org/Magick++/Enumerations.html#VirtualPixelMethod">VirtualPixelMethod</a> 2980virtualPixelMethod_</small></font></small></td> 2981 <td><font size="-1">Image virtual pixel method.</font></td> 2982 </tr> 2983 <tr> 2984 <td> 2985 <center><a name="x11Display"></a> <font size="-1">x11Display</font></center> 2986 </td> 2987 <td><font size="-1">string (e.g. "hostname:0.0")</font></td> 2988 <td><font size="-1">void</font></td> 2989 <td><font size="-1">const string &display_</font></td> 2990 <td><font size="-1">X11 display to display to, obtain fonts from, 2991or to capture image from</font></td> 2992 </tr> 2993 <tr> 2994 <td> 2995 <center><a name="xResolution"></a> <font size="-1">xResolution</font></center> 2996 </td> 2997 <td><font size="-1">double</font></td> 2998 <td><font size="-1">void</font></td> 2999 <td bgcolor="#666666"><font size="-1"> </font></td> 3000 <td><font size="-1">x resolution of the image</font></td> 3001 </tr> 3002 <tr> 3003 <td> 3004 <center><a name="yResolution"></a> <font size="-1">yResolution</font></center> 3005 </td> 3006 <td><font size="-1">double</font></td> 3007 <td><font size="-1">void</font></td> 3008 <td bgcolor="#666666"><font size="-1"> </font></td> 3009 <td><font size="-1">y resolution of the image</font></td> 3010 </tr> 3011 </tbody> 3012</table></ul> 3013</div> 3014<h2> <a name="Raw Image Pixel Access"></a> Low-Level Image Pixel Access</h2> 3015<div class="doc-section"> 3016Image pixels (of type <i><a href="http://www.imagemagick.org/Magick++/PixelPacket.html">PixelPacket</a> </i>) 3017may be accessed directly via the <i>Image Pixel Cache</i> . The 3018image pixel cache is a rectangular window into the actual image pixels 3019(which may be in memory, memory-mapped from a disk file, or entirely on 3020disk). Two interfaces exist to access the <i>Image Pixel Cache.</i> 3021The 3022interface described here (part of the <i>Image</i> class) supports 3023only 3024one view at a time. See the <i><a href="http://www.imagemagick.org/Magick++/Pixels.html">Pixels</a> </i> 3025class for a more abstract interface which supports simultaneous pixel 3026views (up to the number of rows). As an analogy, the interface 3027described 3028here relates to the <i><a href="http://www.imagemagick.org/Magick++/Pixels.html">Pixels</a> </i> class as 3029stdio's gets() relates to fgets(). The <i><a href="http://www.imagemagick.org/Magick++/Pixels.html"> Pixels</a> 3030</i>class provides the more general form of the interface. 3031<p>Obtain existing image pixels via <i>getPixels()</i>. Create a new 3032pixel region using <i>setPixels().</i></p> 3033<p>In order to ensure that only the current generation of the image is 3034modified, the Image's <a href="Image++.html#modifyImage">modifyImage()</a> method 3035should be invoked to reduce the reference count on the underlying image 3036to one. If this is not done, then it is possible for a previous 3037generation of the image to be modified due to the use of reference 3038counting when copying or constructing an Image.<br> 3039</p> 3040<p>Depending on the capabilities of the operating system, and the 3041relationship of the window to the image, the pixel cache may be a copy 3042of the pixels in the selected window, or it may be the actual image 3043pixels. In any case calling <i>syncPixels()</i> insures that the base 3044image is updated with the contents of the modified pixel cache. The 3045method <i> readPixels()</i> supports copying foreign pixel data 3046formats 3047into the pixel cache according to the <i>QuantumTypes</i>. The method <i>writePixels()</i> 3048supports copying the pixels in the cache to a foreign pixel 3049representation according to the format specified by <i>QuantumTypes</i>.</p> 3050<p>The pixel region is effectively a small image in which the pixels 3051may be accessed, addressed, and updated, as shown in the following 3052example: 3053<pre class="code"> 3054<p><img class="icon" src="../../api/Cache.png" name="Graphic1" width="254" border="0" /></p> 3055Image image("cow.png"); 3056// Ensure that there are no other references to this image. 3057image.modifyImage(); 3058// Set the image type to TrueColor DirectClass representation. 3059image.type(TrueColorType); 3060// Request pixel region with size 60x40, and top origin at 20x30 3061ssize_t columns = 60; 3062PixelPacket *pixel_cache = image.getPixels(20,30,columns,40); 3063// Set pixel at column 5, and row 10 in the pixel cache to red. 3064ssize_t column = 5; 3065ssize_t row = 10; 3066PixelPacket *pixel = pixel_cache+row*columns+column; 3067*pixel = Color("red"); 3068// Save changes to underlying image . 3069image.syncPixels(); 3070 // Save updated image to file. 3071image.write("horse.png"); 3072</pre> 3073</p> 3074<p>The image cache supports the following methods: <br> 3075 3076<ul><table border="1" width="100%"> 3077 <caption>Image Cache Methods</caption> <tbody> 3078 <tr> 3079 <td> 3080 <center><b>Method</b></center> 3081 </td> 3082 <td> 3083 <center><b>Returns</b></center> 3084 </td> 3085 <td> 3086 <center><b>Signature</b></center> 3087 </td> 3088 <td> 3089 <center><b>Description</b></center> 3090 </td> 3091 </tr> 3092 <tr> 3093 <td> 3094 <center><a name="getConstPixels"></a> <font size="-1">getConstPixels</font></center> 3095 </td> 3096 <td><font size="-1">const <a href="http://www.imagemagick.org/Magick++/PixelPacket.html">PixelPacket</a> 3097*</font></td> 3098 <td><font size="-1">const ssize_t x_, const ssize_t y_, const size_t 3099columns_, const size_t rows_</font></td> 3100 <td><font size="-1">Transfers pixels from the image to the pixel 3101cache as defined by the specified rectangular region. </font><font 3102 size="-1">The returned pointer remains valid until the next getPixel, 3103getConstPixels, or setPixels call and should never be deallocated by 3104the 3105user.</font></td> 3106 </tr> 3107 <tr> 3108 <td> 3109 <center><a name="getConstIndexes"></a> <font size="-1">getConstIndexes</font></center> 3110 </td> 3111 <td><font size="-1">const IndexPacket*</font></td> 3112 <td><font size="-1">void</font></td> 3113 <td><font size="-1">Returns a pointer to the Image pixel indexes 3114corresponding to a previous </font><font size="-1">getPixel, 3115getConstPixels, or setPixels call. </font><font size="-1">The 3116returned pointer remains valid until the next getPixel, getConstPixels, 3117or setPixels call and should never be deallocated by the user.</font><font 3118 size="-1"> Only valid for PseudoClass images or CMYKA images. The 3119pixel indexes represent an array of type IndexPacket, with each entry 3120corresponding to an x,y pixel position. For PseudoClass images, the 3121entry's value is the offset into the colormap (see <a href="Image++.html#colorMap">colorMap</a> 3122) for that pixel. For CMYKA images, the indexes are used to contain the 3123alpha channel.</font></td> 3124 </tr> 3125 <tr> 3126 <td> 3127 <center><a name="getIndexes"></a> <font size="-1">getIndexes</font></center> 3128 </td> 3129 <td><font size="-1">IndexPacket*</font></td> 3130 <td><font size="-1">void</font></td> 3131 <td><font size="-1">Returns a pointer to the Image pixel indexes 3132corresponding to the pixel region requested by the last <a 3133 href="Image++.html#getConstPixels">getConstPixels</a> , <a href="Image++.html#getPixels">getPixels</a> 3134, or <a href="Image++.html#setPixels">setPixels</a> call. </font><font 3135 size="-1">The 3136returned pointer remains valid until the next getPixel, getConstPixels, 3137or setPixels call and should never be deallocated by the user.</font><font 3138 size="-1"> </font><font size="-1">Only valid for PseudoClass images 3139or 3140CMYKA images. The pixel indexes represent an array of type 3141IndexPacket, with each entry corresponding to a pixel x,y position. For 3142PseudoClass images, the entry's value is the offset into the colormap 3143(see <a href="Image++.html#colorMap">colorMap</a> ) for that pixel. For 3144CMYKA 3145images, the indexes are used to contain the alpha channel.</font></td> 3146 </tr> 3147 <tr> 3148 <td> 3149 <center><a name="getPixels"></a> <font size="-1">getPixels</font></center> 3150 </td> 3151 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/PixelPacket.html">PixelPacket</a> *</font></td> 3152 <td><font size="-1">const ssize_t x_, const ssize_t y_, const size_t 3153columns_, const size_t rows_</font></td> 3154 <td><font size="-1">Transfers pixels from the image to the pixel 3155cache as defined by the specified rectangular region. Modified pixels 3156may be subsequently transferred back to the image via syncPixels. </font><font 3157 size="-1">The returned pointer remains valid until the next getPixel, 3158getConstPixels, or setPixels call and should never be deallocated by 3159the 3160user.</font><font size="-1"></font></td> 3161 </tr> 3162 <tr> 3163 <td> 3164 <center><a name="setPixels"></a> <font size="-1">setPixels</font></center> 3165 </td> 3166 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/PixelPacket.html">PixelPacket</a> *</font></td> 3167 <td><font size="-1">const ssize_t x_, const ssize_t y_, const size_t 3168columns_, const size_t rows_</font></td> 3169 <td><font size="-1">Allocates a pixel cache region to store image 3170pixels as defined by the region rectangle. This area is 3171subsequently transferred from the pixel cache to the image via 3172syncPixels. </font><font size="-1">The returned pointer remains 3173valid until the next getPixel, getConstPixels, or setPixels call and 3174should never be deallocated by the user.</font></td> 3175 </tr> 3176 <tr> 3177 <td> 3178 <center><a name="syncPixels"></a> <font size="-1">syncPixels</font></center> 3179 </td> 3180 <td><font size="-1">void</font></td> 3181 <td><font size="-1">void</font></td> 3182 <td><font size="-1">Transfers the image cache pixels to the image.</font></td> 3183 </tr> 3184 <tr> 3185 <td> 3186 <center><a name="readPixels"></a> <font size="-1">readPixels</font></center> 3187 </td> 3188 <td><font size="-1">void</font></td> 3189 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#QuantumTypes">QuantumTypes</a> 3190quantum_, unsigned char *source_,</font></td> 3191 <td><font size="-1">Transfers one or more pixel components from a 3192buffer or file into the image pixel cache of an image. ReadPixels is 3193typically used to support image decoders. The region transferred 3194corresponds to the region set by a preceding setPixels call.</font></td> 3195 </tr> 3196 <tr> 3197 <td> 3198 <center><a name="writePixels"></a> <font size="-1">writePixels</font></center> 3199 </td> 3200 <td><font size="-1">void</font></td> 3201 <td><font size="-1"><a href="http://www.imagemagick.org/Magick++/Enumerations.html#QuantumTypes">QuantumTypes</a> 3202quantum_, unsigned char *destination_</font></td> 3203 <td><font size="-1">Transfers one or more pixel components from 3204the image pixel cache to a buffer or file. WritePixels is typically 3205used to support image encoders. The region transferred corresponds to 3206the region set by a preceding getPixels or getConstPixels call.</font></td> 3207 </tr> 3208 </tbody> 3209</table></ul> 3210</p> 3211</div> 3212</div> 3213 </div> 3214 </main><!-- /.container --> 3215 <footer class="magick-footer"> 3216 <p><a href="../../www/security-policy.html">Security</a> • 3217 <a href="../../www/architecture.html">Architecture</a> • 3218 <a href="../../www/links.html">Related</a> • 3219 <a href="../../www/sitemap.html">Sitemap</a> 3220 3221 <a href="Image++.html#"><img class="d-inline" id="wand" alt="And Now a Touch of Magick" width="16" height="16" src="../../images/wand.ico"/></a> 3222 3223 <a href="http://pgp.mit.edu/pks/lookup?op=get&search=0x89AB63D48277377A">Public Key</a> • 3224 <a href="../../www/support.html">Donate</a> • 3225 <a href="../../www/contact.html">Contact Us</a> 3226 <br/> 3227 <small>© 1999-2019 ImageMagick Studio LLC</small></p> 3228 </footer> 3229 3230 <!-- Javascript assets --> 3231 <script src="../assets/magick.js" crossorigin="anonymous"></script> 3232 <script>window.jQuery || document.write('<script src="https://localhost/ajax/libs/jquery/3.3.1/jquery.min.js"><\/script>')</script> 3233</body> 3234</html> 3235<!-- Magick Cache 30th December 2018 07:43 -->