1 2 3 4 5<!DOCTYPE html> 6<html lang="en"> 7<head> 8 <meta name="google-site-verification" content="_bMOCDpkx9ZAzBwb2kF3PRHbfUUdFj2uO8Jd1AXArz4" /> 9 <title>ImageMagick: MagickCore, C API for ImageMagick: Add a Special Effect</title> 10 <meta http-equiv="content-type" content="text/html; charset=utf-8"/> 11 <meta name="application-name" content="ImageMagick"/> 12 <meta name="description" content="ImageMagick® is a software suite to create, edit, compose, or convert bitmap images. It can read and write images in a variety of formats (over 200) including PNG, JPEG, JPEG-2000, GIF, WebP, Postscript, PDF, and SVG. Use ImageMagick to resize, flip, mirror, rotate, distort, shear and transform images, adjust image colors, apply various special effects, or draw text, lines, polygons, ellipses and Bézier curves."/> 13 <meta name="application-url" content="http://www.imagemagick.org"/> 14 <meta name="generator" content="PHP"/> 15 <meta name="keywords" content="magickcore, c, api, for, imagemagick:, add, a, special, effect, 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-2016 ImageMagick Studio LLC"/> 23 <meta name="distribution" content="Global"/> 24 <meta name="magick-serial" content="P131-S030410-R485315270133-P82224-A6668-G1245-1"/> 25 <link rel="icon" href="../image/wand.png"/> 26 <link rel="shortcut icon" href="../image/wand.ico"/> 27 <link rel="stylesheet" href="../css/magick.php"/> 28</head> 29<body> 30<div class="main"> 31<div class="magick-masthead"> 32 <div class="container"> 33 <script async="async" src="http://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script> <ins class="adsbygoogle" 34 style="display:block" 35 data-ad-client="ca-pub-3129977114552745" 36 data-ad-slot="6345125851" 37 data-ad-format="auto"></ins> 38 <script> 39 (adsbygoogle = window.adsbygoogle || []).push({}); 40 </script> 41 <nav class="magick-nav"> 42 <a class="magick-nav-item " href="../index.php">Home</a> 43 <a class="magick-nav-item " href="../script/binary-releases.php">Download</a> 44 <a class="magick-nav-item " href="../script/command-line-tools.php">Tools</a> 45 <a class="magick-nav-item " href="../script/command-line-options.php">Options</a> 46 <a class="magick-nav-item " href="../script/resources.php">Resources</a> 47 <a class="magick-nav-item " href="../script/api.php">Develop</a> 48 <a class="magick-nav-item " href="../script/search.php">Search</a> 49 <a class="magick-nav-item pull-right" href="http://www.imagemagick.org/discourse-server/">Community</a> 50 </nav> 51 </div> 52</div> 53<div class="container"> 54<div class="magick-header"> 55<p class="text-center"><a href="fx.php#AddNoiseImage">AddNoiseImage</a> • <a href="fx.php#BlueShiftImage">BlueShiftImage</a> • <a href="fx.php#CharcoalImage">CharcoalImage</a> • <a href="fx.php#ColorizeImage">ColorizeImage</a> • <a href="fx.php#ColorMatrixImage">ColorMatrixImage</a> • <a href="fx.php#FxImage">FxImage</a> • <a href="fx.php#ImplodeImage">ImplodeImage</a> • <a href="fx.php#The MorphImages">The MorphImages</a> • <a href="fx.php#PlasmaImage">PlasmaImage</a> • <a href="fx.php#PolaroidImage">PolaroidImage</a> • <a href="fx.php#MagickSepiaToneImage">MagickSepiaToneImage</a> • <a href="fx.php#ShadowImage">ShadowImage</a> • <a href="fx.php#SketchImage">SketchImage</a> • <a href="fx.php#SolarizeImage">SolarizeImage</a> • <a href="fx.php#SteganoImage">SteganoImage</a> • <a href="fx.php#StereoAnaglyphImage">StereoAnaglyphImage</a> • <a href="fx.php#SwirlImage">SwirlImage</a> • <a href="fx.php#TintImage">TintImage</a> • <a href="fx.php#VignetteImage">VignetteImage</a> • <a href="fx.php#WaveImage">WaveImage</a></p> 56 57<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="AddNoiseImage">AddNoiseImage</a></h2> 58 59<p>AddNoiseImage() adds random noise to the image.</p> 60 61<p>The format of the AddNoiseImage method is:</p> 62 63<pre class="text"> 64Image *AddNoiseImage(const Image *image,const NoiseType noise_type, 65 const double attenuate,ExceptionInfo *exception) 66</pre> 67 68<p>A description of each parameter follows:</p> 69 70<dd> 71</dd> 72 73<dd> </dd> 74<dl class="dl-horizontal"> 75<dt>image</dt> 76<dd>the image. </dd> 77 78<dd> </dd> 79<dt>channel</dt> 80<dd>the channel type. </dd> 81 82<dd> </dd> 83<dt>noise_type</dt> 84<dd> The type of noise: Uniform, Gaussian, Multiplicative, Impulse, Laplacian, or Poisson. </dd> 85 86<dd> </dd> 87<dt>attenuate</dt> 88<dd> attenuate the random distribution. </dd> 89 90<dd> </dd> 91<dt>exception</dt> 92<dd>return any errors or warnings in this structure. </dd> 93 94<dd> </dd> 95</dl> 96<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="BlueShiftImage">BlueShiftImage</a></h2> 97 98<p>BlueShiftImage() mutes the colors of the image to simulate a scene at nighttime in the moonlight.</p> 99 100<p>The format of the BlueShiftImage method is:</p> 101 102<pre class="text"> 103Image *BlueShiftImage(const Image *image,const double factor, 104 ExceptionInfo *exception) 105</pre> 106 107<p>A description of each parameter follows:</p> 108 109<dd> 110</dd> 111 112<dd> </dd> 113<dl class="dl-horizontal"> 114<dt>image</dt> 115<dd>the image. </dd> 116 117<dd> </dd> 118<dt>factor</dt> 119<dd>the shift factor. </dd> 120 121<dd> </dd> 122<dt>exception</dt> 123<dd>return any errors or warnings in this structure. </dd> 124 125<dd> </dd> 126</dl> 127<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="CharcoalImage">CharcoalImage</a></h2> 128 129<p>CharcoalImage() creates a new image that is a copy of an existing one with the edge highlighted. It allocates the memory necessary for the new Image structure and returns a pointer to the new image.</p> 130 131<p>The format of the CharcoalImage method is:</p> 132 133<pre class="text"> 134Image *CharcoalImage(const Image *image,const double radius, 135 const double sigma,ExceptionInfo *exception) 136</pre> 137 138<p>A description of each parameter follows:</p> 139 140<dd> 141</dd> 142 143<dd> </dd> 144<dl class="dl-horizontal"> 145<dt>image</dt> 146<dd>the image. </dd> 147 148<dd> </dd> 149<dt>radius</dt> 150<dd>the radius of the pixel neighborhood. </dd> 151 152<dd> </dd> 153<dt>sigma</dt> 154<dd>the standard deviation of the Gaussian, in pixels. </dd> 155 156<dd> </dd> 157<dt>exception</dt> 158<dd>return any errors or warnings in this structure. </dd> 159 160<dd> </dd> 161</dl> 162<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="ColorizeImage">ColorizeImage</a></h2> 163 164<p>ColorizeImage() blends the fill color with each pixel in the image. A percentage blend is specified with opacity. Control the application of different color components by specifying a different percentage for each component (e.g. 90/100/10 is 90 red, 100 green, and 10 blue).</p> 165 166<p>The format of the ColorizeImage method is:</p> 167 168<pre class="text"> 169Image *ColorizeImage(const Image *image,const char *blend, 170 const PixelInfo *colorize,ExceptionInfo *exception) 171</pre> 172 173<p>A description of each parameter follows:</p> 174 175<dd> 176</dd> 177 178<dd> </dd> 179<dl class="dl-horizontal"> 180<dt>image</dt> 181<dd>the image. </dd> 182 183<dd> </dd> 184<dt>blend</dt> 185<dd> A character string indicating the level of blending as a percentage. </dd> 186 187<dd> </dd> 188<dt>colorize</dt> 189<dd>A color value. </dd> 190 191<dd> </dd> 192<dt>exception</dt> 193<dd>return any errors or warnings in this structure. </dd> 194 195<dd> </dd> 196</dl> 197<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="ColorMatrixImage">ColorMatrixImage</a></h2> 198 199<p>ColorMatrixImage() applies color transformation to an image. This method permits saturation changes, hue rotation, luminance to alpha, and various other effects. Although variable-sized transformation matrices can be used, typically one uses a 5x5 matrix for an RGBA image and a 6x6 for CMYKA (or RGBA with offsets). The matrix is similar to those used by Adobe Flash except offsets are in column 6 rather than 5 (in support of CMYKA images) and offsets are normalized (divide Flash offset by 255).</p> 200 201<p>The format of the ColorMatrixImage method is:</p> 202 203<pre class="text"> 204Image *ColorMatrixImage(const Image *image, 205 const KernelInfo *color_matrix,ExceptionInfo *exception) 206</pre> 207 208<p>A description of each parameter follows:</p> 209 210<dd> 211</dd> 212 213<dd> </dd> 214<dl class="dl-horizontal"> 215<dt>image</dt> 216<dd>the image. </dd> 217 218<dd> </dd> 219<dt>color_matrix</dt> 220<dd> the color matrix. </dd> 221 222<dd> </dd> 223<dt>exception</dt> 224<dd>return any errors or warnings in this structure. </dd> 225 226<dd> </dd> 227</dl> 228<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="FxImage">FxImage</a></h2> 229 230<p>FxImage() applies a mathematical expression to the specified image.</p> 231 232<p>The format of the FxImage method is:</p> 233 234<pre class="text"> 235Image *FxImage(const Image *image,const char *expression, 236 ExceptionInfo *exception) 237</pre> 238 239<p>A description of each parameter follows:</p> 240 241<dd> 242</dd> 243 244<dd> </dd> 245<dl class="dl-horizontal"> 246<dt>image</dt> 247<dd>the image. </dd> 248 249<dd> </dd> 250<dt>expression</dt> 251<dd>A mathematical expression. </dd> 252 253<dd> </dd> 254<dt>exception</dt> 255<dd>return any errors or warnings in this structure. </dd> 256 257<dd> </dd> 258</dl> 259<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="ImplodeImage">ImplodeImage</a></h2> 260 261<p>ImplodeImage() creates a new image that is a copy of an existing one with the image pixels "implode" by the specified percentage. It allocates the memory necessary for the new Image structure and returns a pointer to the new image.</p> 262 263<p>The format of the ImplodeImage method is:</p> 264 265<pre class="text"> 266Image *ImplodeImage(const Image *image,const double amount, 267 const PixelInterpolateMethod method,ExceptionInfo *exception) 268</pre> 269 270<p>A description of each parameter follows:</p> 271 272<dd> 273</dd> 274 275<dd> </dd> 276<dl class="dl-horizontal"> 277<dt>implode_image</dt> 278<dd>Method ImplodeImage returns a pointer to the image after it is implode. A null image is returned if there is a memory shortage. </dd> 279 280<dd> </dd> 281<dt>image</dt> 282<dd>the image. </dd> 283 284<dd> </dd> 285<dt>amount</dt> 286<dd> Define the extent of the implosion. </dd> 287 288<dd> </dd> 289<dt>method</dt> 290<dd>the pixel interpolation method. </dd> 291 292<dd> </dd> 293<dt>exception</dt> 294<dd>return any errors or warnings in this structure. </dd> 295 296<dd> </dd> 297</dl> 298<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="The_MorphImages">The MorphImages</a></h2> 299 300<p>The MorphImages() method requires a minimum of two images. The first image is transformed into the second by a number of intervening images as specified by frames.</p> 301 302<p>The format of the MorphImage method is:</p> 303 304<pre class="text"> 305Image *MorphImages(const Image *image,const size_t number_frames, 306 ExceptionInfo *exception) 307</pre> 308 309<p>A description of each parameter follows:</p> 310 311<dd> 312</dd> 313 314<dd> </dd> 315<dl class="dl-horizontal"> 316<dt>image</dt> 317<dd>the image. </dd> 318 319<dd> </dd> 320<dt>number_frames</dt> 321<dd> Define the number of in-between image to generate. The more in-between frames, the smoother the morph. </dd> 322 323<dd> </dd> 324<dt>exception</dt> 325<dd>return any errors or warnings in this structure. </dd> 326 327<dd> </dd> 328</dl> 329<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="PlasmaImage">PlasmaImage</a></h2> 330 331<p>PlasmaImage() initializes an image with plasma fractal values. The image must be initialized with a base color and the random number generator seeded before this method is called.</p> 332 333<p>The format of the PlasmaImage method is:</p> 334 335<pre class="text"> 336MagickBooleanType PlasmaImage(Image *image,const SegmentInfo *segment, 337 size_t attenuate,size_t depth,ExceptionInfo *exception) 338</pre> 339 340<p>A description of each parameter follows:</p> 341 342<dd> 343</dd> 344 345<dd> </dd> 346<dl class="dl-horizontal"> 347<dt>image</dt> 348<dd>the image. </dd> 349 350<dd> </dd> 351<dt>segment</dt> 352<dd> Define the region to apply plasma fractals values. </dd> 353 354<dd> </dd> 355<dt>attenuate</dt> 356<dd>Define the plasma attenuation factor. </dd> 357 358<dd> </dd> 359<dt>depth</dt> 360<dd>Limit the plasma recursion depth. </dd> 361 362<dd> </dd> 363<dt>exception</dt> 364<dd>return any errors or warnings in this structure. </dd> 365 366<dd> </dd> 367</dl> 368<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="PolaroidImage">PolaroidImage</a></h2> 369 370<p>PolaroidImage() simulates a Polaroid picture.</p> 371 372<p>The format of the PolaroidImage method is:</p> 373 374<pre class="text"> 375Image *PolaroidImage(const Image *image,const DrawInfo *draw_info, 376 const char *caption,const double angle, 377 const PixelInterpolateMethod method,ExceptionInfo exception) 378</pre> 379 380<p>A description of each parameter follows:</p> 381 382<dd> 383</dd> 384 385<dd> </dd> 386<dl class="dl-horizontal"> 387<dt>image</dt> 388<dd>the image. </dd> 389 390<dd> </dd> 391<dt>draw_info</dt> 392<dd>the draw info. </dd> 393 394<dd> </dd> 395<dt>caption</dt> 396<dd>the Polaroid caption. </dd> 397 398<dd> </dd> 399<dt>angle</dt> 400<dd>Apply the effect along this angle. </dd> 401 402<dd> </dd> 403<dt>method</dt> 404<dd>the pixel interpolation method. </dd> 405 406<dd> </dd> 407<dt>exception</dt> 408<dd>return any errors or warnings in this structure. </dd> 409 410<dd> </dd> 411</dl> 412<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="MagickSepiaToneImage">MagickSepiaToneImage</a></h2> 413 414<p>MagickSepiaToneImage() applies a special effect to the image, similar to the effect achieved in a photo darkroom by sepia toning. Threshold ranges from 0 to QuantumRange and is a measure of the extent of the sepia toning. A threshold of 80 is a good starting point for a reasonable tone.</p> 415 416<p>The format of the SepiaToneImage method is:</p> 417 418<pre class="text"> 419Image *SepiaToneImage(const Image *image,const double threshold, 420 ExceptionInfo *exception) 421</pre> 422 423<p>A description of each parameter follows:</p> 424 425<dd> 426</dd> 427 428<dd> </dd> 429<dl class="dl-horizontal"> 430<dt>image</dt> 431<dd>the image. </dd> 432 433<dd> </dd> 434<dt>threshold</dt> 435<dd>the tone threshold. </dd> 436 437<dd> </dd> 438<dt>exception</dt> 439<dd>return any errors or warnings in this structure. </dd> 440 441<dd> </dd> 442</dl> 443<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="ShadowImage">ShadowImage</a></h2> 444 445<p>ShadowImage() simulates a shadow from the specified image and returns it.</p> 446 447<p>The format of the ShadowImage method is:</p> 448 449<pre class="text"> 450Image *ShadowImage(const Image *image,const double alpha, 451 const double sigma,const ssize_t x_offset,const ssize_t y_offset, 452 ExceptionInfo *exception) 453</pre> 454 455<p>A description of each parameter follows:</p> 456 457<dd> 458</dd> 459 460<dd> </dd> 461<dl class="dl-horizontal"> 462<dt>image</dt> 463<dd>the image. </dd> 464 465<dd> </dd> 466<dt>alpha</dt> 467<dd>percentage transparency. </dd> 468 469<dd> </dd> 470<dt>sigma</dt> 471<dd>the standard deviation of the Gaussian, in pixels. </dd> 472 473<dd> </dd> 474<dt>x_offset</dt> 475<dd>the shadow x-offset. </dd> 476 477<dd> </dd> 478<dt>y_offset</dt> 479<dd>the shadow y-offset. </dd> 480 481<dd> </dd> 482<dt>exception</dt> 483<dd>return any errors or warnings in this structure. </dd> 484 485<dd> </dd> 486</dl> 487<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="SketchImage">SketchImage</a></h2> 488 489<p>SketchImage() simulates a pencil sketch. We convolve the image with a Gaussian operator of the given radius and standard deviation (sigma). For reasonable results, radius should be larger than sigma. Use a radius of 0 and SketchImage() selects a suitable radius for you. Angle gives the angle of the sketch.</p> 490 491<p>The format of the SketchImage method is:</p> 492 493<pre class="text"> 494 Image *SketchImage(const Image *image,const double radius, 495const double sigma,const double angle,ExceptionInfo *exception) 496</pre> 497 498<p>A description of each parameter follows:</p> 499 500<dd> 501</dd> 502 503<dd> </dd> 504<dl class="dl-horizontal"> 505<dt>image</dt> 506<dd>the image. </dd> 507 508<dd> </dd> 509<dt>radius</dt> 510<dd>the radius of the Gaussian, in pixels, not counting the center pixel. </dd> 511 512<dd> </dd> 513<dt>sigma</dt> 514<dd>the standard deviation of the Gaussian, in pixels. </dd> 515 516<dd> </dd> 517<dt>angle</dt> 518<dd>apply the effect along this angle. </dd> 519 520<dd> </dd> 521<dt>exception</dt> 522<dd>return any errors or warnings in this structure. </dd> 523 524<dd> </dd> 525</dl> 526<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="SolarizeImage">SolarizeImage</a></h2> 527 528<p>SolarizeImage() applies a special effect to the image, similar to the effect achieved in a photo darkroom by selectively exposing areas of photo sensitive paper to light. Threshold ranges from 0 to QuantumRange and is a measure of the extent of the solarization.</p> 529 530<p>The format of the SolarizeImage method is:</p> 531 532<pre class="text"> 533MagickBooleanType SolarizeImage(Image *image,const double threshold, 534 ExceptionInfo *exception) 535</pre> 536 537<p>A description of each parameter follows:</p> 538 539<dd> 540</dd> 541 542<dd> </dd> 543<dl class="dl-horizontal"> 544<dt>image</dt> 545<dd>the image. </dd> 546 547<dd> </dd> 548<dt>threshold</dt> 549<dd> Define the extent of the solarization. </dd> 550 551<dd> </dd> 552<dt>exception</dt> 553<dd>return any errors or warnings in this structure. </dd> 554 555<dd> </dd> 556</dl> 557<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="SteganoImage">SteganoImage</a></h2> 558 559<p>SteganoImage() hides a digital watermark within the image. Recover the hidden watermark later to prove that the authenticity of an image. Offset defines the start position within the image to hide the watermark.</p> 560 561<p>The format of the SteganoImage method is:</p> 562 563<pre class="text"> 564Image *SteganoImage(const Image *image,Image *watermark, 565 ExceptionInfo *exception) 566</pre> 567 568<p>A description of each parameter follows:</p> 569 570<dd> 571</dd> 572 573<dd> </dd> 574<dl class="dl-horizontal"> 575<dt>image</dt> 576<dd>the image. </dd> 577 578<dd> </dd> 579<dt>watermark</dt> 580<dd>the watermark image. </dd> 581 582<dd> </dd> 583<dt>exception</dt> 584<dd>return any errors or warnings in this structure. </dd> 585 586<dd> </dd> 587</dl> 588<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="StereoAnaglyphImage">StereoAnaglyphImage</a></h2> 589 590<p>StereoAnaglyphImage() combines two images and produces a single image that is the composite of a left and right image of a stereo pair. Special red-green stereo glasses are required to view this effect.</p> 591 592<p>The format of the StereoAnaglyphImage method is:</p> 593 594<pre class="text"> 595Image *StereoImage(const Image *left_image,const Image *right_image, 596 ExceptionInfo *exception) 597Image *StereoAnaglyphImage(const Image *left_image, 598 const Image *right_image,const ssize_t x_offset,const ssize_t y_offset, 599 ExceptionInfo *exception) 600</pre> 601 602<p>A description of each parameter follows:</p> 603 604<dd> 605</dd> 606 607<dd> </dd> 608<dl class="dl-horizontal"> 609<dt>left_image</dt> 610<dd>the left image. </dd> 611 612<dd> </dd> 613<dt>right_image</dt> 614<dd>the right image. </dd> 615 616<dd> </dd> 617<dt>exception</dt> 618<dd>return any errors or warnings in this structure. </dd> 619 620<dd> </dd> 621<dt>x_offset</dt> 622<dd>amount, in pixels, by which the left image is offset to the right of the right image. </dd> 623 624<dd> </dd> 625<dt>y_offset</dt> 626<dd>amount, in pixels, by which the left image is offset to the bottom of the right image. </dd> 627 628<dd> </dd> 629 630<dd> </dd> 631</dl> 632<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="SwirlImage">SwirlImage</a></h2> 633 634<p>SwirlImage() swirls the pixels about the center of the image, where degrees indicates the sweep of the arc through which each pixel is moved. You get a more dramatic effect as the degrees move from 1 to 360.</p> 635 636<p>The format of the SwirlImage method is:</p> 637 638<pre class="text"> 639Image *SwirlImage(const Image *image,double degrees, 640 const PixelInterpolateMethod method,ExceptionInfo *exception) 641</pre> 642 643<p>A description of each parameter follows:</p> 644 645<dd> 646</dd> 647 648<dd> </dd> 649<dl class="dl-horizontal"> 650<dt>image</dt> 651<dd>the image. </dd> 652 653<dd> </dd> 654<dt>degrees</dt> 655<dd>Define the tightness of the swirling effect. </dd> 656 657<dd> </dd> 658<dt>method</dt> 659<dd>the pixel interpolation method. </dd> 660 661<dd> </dd> 662<dt>exception</dt> 663<dd>return any errors or warnings in this structure. </dd> 664 665<dd> </dd> 666</dl> 667<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="TintImage">TintImage</a></h2> 668 669<p>TintImage() applies a color vector to each pixel in the image. The length of the vector is 0 for black and white and at its maximum for the midtones. The vector weighting function is f(x)=(1-(4.0*((x-0.5)*(x-0.5))))</p> 670 671<p>The format of the TintImage method is:</p> 672 673<pre class="text"> 674Image *TintImage(const Image *image,const char *blend, 675 const PixelInfo *tint,ExceptionInfo *exception) 676</pre> 677 678<p>A description of each parameter follows:</p> 679 680<dd> 681</dd> 682 683<dd> </dd> 684<dl class="dl-horizontal"> 685<dt>image</dt> 686<dd>the image. </dd> 687 688<dd> </dd> 689<dt>blend</dt> 690<dd>A color value used for tinting. </dd> 691 692<dd> </dd> 693<dt>tint</dt> 694<dd>A color value used for tinting. </dd> 695 696<dd> </dd> 697<dt>exception</dt> 698<dd>return any errors or warnings in this structure. </dd> 699 700<dd> </dd> 701</dl> 702<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="VignetteImage">VignetteImage</a></h2> 703 704<p>VignetteImage() softens the edges of the image in vignette style.</p> 705 706<p>The format of the VignetteImage method is:</p> 707 708<pre class="text"> 709Image *VignetteImage(const Image *image,const double radius, 710 const double sigma,const ssize_t x,const ssize_t y, 711 ExceptionInfo *exception) 712</pre> 713 714<p>A description of each parameter follows:</p> 715 716<dd> 717</dd> 718 719<dd> </dd> 720<dl class="dl-horizontal"> 721<dt>image</dt> 722<dd>the image. </dd> 723 724<dd> </dd> 725<dt>radius</dt> 726<dd>the radius of the pixel neighborhood. </dd> 727 728<dd> </dd> 729<dt>sigma</dt> 730<dd>the standard deviation of the Gaussian, in pixels. </dd> 731 732<dd> </dd> 733<dt>x, y</dt> 734<dd> Define the x and y ellipse offset. </dd> 735 736<dd> </dd> 737<dt>exception</dt> 738<dd>return any errors or warnings in this structure. </dd> 739 740<dd> </dd> 741</dl> 742<h2><a href="http://nextgen.imagemagick.org/api/MagickCore/fx_8c.html" id="WaveImage">WaveImage</a></h2> 743 744<p>WaveImage() creates a "ripple" effect in the image by shifting the pixels vertically along a sine wave whose amplitude and wavelength is specified by the given parameters.</p> 745 746<p>The format of the WaveImage method is:</p> 747 748<pre class="text"> 749Image *WaveImage(const Image *image,const double amplitude, 750 const double wave_length,const PixelInterpolateMethod method, 751 ExceptionInfo *exception) 752</pre> 753 754<p>A description of each parameter follows:</p> 755 756<dd> 757</dd> 758 759<dd> </dd> 760<dl class="dl-horizontal"> 761<dt>image</dt> 762<dd>the image. </dd> 763 764<dd> </dd> 765<dt>amplitude, wave_length</dt> 766<dd> Define the amplitude and wave length of the sine wave. </dd> 767 768<dd> </dd> 769<dt>interpolate</dt> 770<dd>the pixel interpolation method. </dd> 771 772<dd> </dd> 773<dt>exception</dt> 774<dd>return any errors or warnings in this structure. </dd> 775 776<dd> </dd> 777</dl> 778</div> 779 <footer class="magick-footer"> 780 <p><a href="../script/support.php">Donate</a> • 781 <a href="../script/sitemap.php">Sitemap</a> • 782 <a href="../script/links.php">Related</a> • 783 <a href="../script/architecture.php">Architecture</a> 784</p> 785 <p><a href="fx.php#">Back to top</a> • 786 <a href="http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x89AB63D48277377A">Public Key</a> • 787 <a href="../script/contact.php">Contact Us</a></p> 788 <p><small>© 1999-2016 ImageMagick Studio LLC</small></p> 789 </footer> 790</div><!-- /.container --> 791 792 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script> 793 <script src="http://nextgen.imagemagick.org/js/magick.php"></script> 794</div> 795</body> 796</html> 797