blob: 1a1b6ebee3e752b4872bc6e6adab0c06e832d5e8 [file] [log] [blame]
cristydcca3fa2010-12-29 21:50:07 +00001<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
2 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
3<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" dir="ltr">
cristy10c87152010-06-26 16:12:21 +00004<head>
cristy3c98a4f2010-08-13 20:09:41 +00005 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
6 <meta name="verify-v1" content="g222frIIxcQTrvDR3NBRUSKP3AnMNoqxOkIniCEkV7U="/>
cristyffb69ed2010-12-25 00:06:48 +00007 <title>ImageMagick: MagickCore, C API for ImageMagick: Image View Methods</title>
cristy10c87152010-06-26 16:12:21 +00008 <meta http-equiv="Content-Language" content="en-US"/>
9 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
10 <meta http-equiv="Reply-to" content="magick-users@imagemagick.org"/>
cristy3c98a4f2010-08-13 20:09:41 +000011 <meta name="Application-name" content="ImageMagick"/>
cristydcca3fa2010-12-29 21:50:07 +000012 <meta name="Description" content="ImageMagick is a software suite to create, edit, compose, or convert bitmap images in a variety of formats. Use ImageMagick to scale, rotate, shear, distort and transform images."/>
cristy3c98a4f2010-08-13 20:09:41 +000013 <meta name="Application-url" content="http://www.imagemagick.org"/>
cristy10c87152010-06-26 16:12:21 +000014 <meta name="Generator" content="PHP"/>
15 <meta name="Keywords" content="magickcore, c, api, for, imagemagick:, image, view, methods, ImageMagick, ImageMagic, MagickCore, MagickWand, PerlMagick, Magick++, RMagick, PythonMagick, JMagick, TclMagick, Image, Magick, Magic, Wand, ImageMagickObject, Swiss, Army, Knife, Image, Processing"/>
cristy10c87152010-06-26 16:12:21 +000016 <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"/>
cristy4103d562010-12-10 01:38:54 +000022 <meta name="Copyright" content="Copyright (c) 1999-2011 ImageMagick Studio LLC"/>
cristy10c87152010-06-26 16:12:21 +000023 <meta name="Distribution" content="Global"/>
cristydcca3fa2010-12-29 21:50:07 +000024 <link rel="icon" href="../../images/wand.png"/>
cristy3c98a4f2010-08-13 20:09:41 +000025 <link rel="shortcut icon" href="../../images/wand.ico" type="images/x-icon"/>
26 <link rel="meta" type="application/rdf+xml" title="ICI" href="http://imagemagick.org/ici.rdf"/>
cristy7a40ba82011-01-08 20:31:18 +000027 <link rel="stylesheet" href="http://www.google.com/cse/style/look/default.css" type="text/css" />
cristy3c98a4f2010-08-13 20:09:41 +000028 <style type="text/css" media="all">
29 @import url("../../www/magick.css");
30 </style>
cristydcca3fa2010-12-29 21:50:07 +000031 <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
cristy361f4662010-12-31 23:02:52 +000032 <script type="text/javascript" src="../fancybox/jquery.fancybox-1.3.4.pack.js"></script>
33 <link rel="stylesheet" type="text/css" href="../fancybox/jquery.fancybox-1.3.4.css" media="screen" />
34 <script type="text/javascript">
35 $(document).ready(function() {
36 $("a[href$=.jpg],a[href$=.png],a[href$=.gif]").fancybox({
37 'transitionIn' : 'elastic',
38 'transitionOut' : 'elastic',
39 'overlayShow' : false,
40 'opacity' : true
41 });
42 });
43 </script>
cristy10c87152010-06-26 16:12:21 +000044</head>
45
46<body id="www-imagemagick-org">
47<div class="titlebar">
48<a href="../../index.html">
49 <img src="../../images/script.png" alt="[ImageMagick]"
50 style="width: 350px; height: 60px; margin: 28px auto; float: left;" /></a>
51<a href="http://www.networkredux.com">
52 <img src="../../images/networkredux.png" alt="[sponsor]"
53 style="margin: 45px auto; border: 0px; float: left;" /></a>
54<a href="http://www.imagemagick.org/discourse-server/">
55 <img src="../../images/logo.jpg" alt=""
56 style="width: 114px; height: 118px; border: 0px; float: right;" /></a>
57<a href="../../index.html">
58 <img src="../../images/sprite.jpg" alt=""
59 style="width: 114px; height: 118px; border: 0px; float: right;" /></a>
60</div>
61
cristyce69bb02010-07-27 19:49:46 +000062<div class="westbar">
cristy10c87152010-06-26 16:12:21 +000063
64<div class="menu">
65 <a title="About ImageMagick" href="../../index.html">About ImageMagick</a>
66</div>
67<div class="sep"></div>
68<div class="menu">
69 <a title="Binary Releases" href="../../www/binary-releases.html">Binary Releases</a>
70</div>
71<div class="sub">
72 <a title="Binary Release: Unix" href="../../www/binary-releases.html#unix">Unix</a>
73</div>
74<div class="sub">
75 <a title="Binary Release: MacOS X" href="../../www/binary-releases.html#macosx">Mac OS X</a>
76</div>
77<div class="sub">
78 <a title="Binary Release: Windows" href="../../www/binary-releases.html#windows">Windows</a>
79</div>
80<div class="sep"></div>
81<div class="menu">
82 <a title="Command-line Tools" href="../../www/command-line-tools.html">Command-line Tools</a>
83</div>
84<div class="sub">
85 <a title="Command-line Tools: Processing" href="../../www/command-line-processing.html">Processing</a>
86</div>
87<div class="sub">
88 <a title="Command-line Tools: Options" href="../../www/command-line-options.html">Options</a>
89</div>
90<div class="sub">
91 <a title="Command-line Tools: Usage" href="http://www.imagemagick.org/Usage/">Usage</a>
92</div>
93<div class="menu">
94 <a title="Program Interfaces" href="../../www/api.html">Program Interfaces</a>
95</div>
96<div class="sub">
97 <a title="Program Interface: MagickWand" href="../../www/magick-wand.html">MagickWand</a>
98</div>
99<div class="sub">
100 <a title="Program Interface: MagickCore" href="../../www/magick-core.html">MagickCore</a>
101</div>
102<div class="sub">
103 <a title="Program Interface: PerlMagick" href="../../www/perl-magick.html">PerlMagick</a>
104</div>
105<div class="sub">
cristydcca3fa2010-12-29 21:50:07 +0000106 <a title="Program Interface: Magick++" href="../../www/magick++.html">Magick++</a>
cristy10c87152010-06-26 16:12:21 +0000107</div>
108<div class="sep"></div>
109<div class="menu">
110 <a title="Install from Source" href="../../www/install-source.html">Install from Source</a>
111</div>
112<div class="sub">
113 <a title="Install from Source: Unix" href="../../www/install-source.html#unix">Unix</a>
114</div>
115<div class="sub">
116 <a title="Install from Source: Windows" href="../../www/install-source.html#windows">Windows</a>
117 </div>
118<div class="menu">
119 <a title="Resources" href="../../www/resources.html">Resources</a>
120</div>
121<div class="menu">
122 <a title="Architecture" href="../../www/architecture.html">Architecture</a>
123</div>
124<div class="menu">
125 <a title="Download" href="../../www/download.html">Download</a>
126</div>
127<div class="sep"></div>
128<div class="menu">
129 <a title="Search" href="../http://www.imagemagick.org/script/search.php">Search</a>
130</div>
131<div class="sep"></div>
132<div class="menu">
cristyffb69ed2010-12-25 00:06:48 +0000133 <a title="Site Map" href="../../www/sitemap.html">Site Map</a>
cristy10c87152010-06-26 16:12:21 +0000134</div>
135<div class="sub">
cristyffb69ed2010-12-25 00:06:48 +0000136 <a title="Site Map: Links" href="../../www/links.html">Links</a>
cristy10c87152010-06-26 16:12:21 +0000137</div>
138<div class="sep"></div>
139<div class="menu">
140 <a title="Sponsors" href="../../www/sponsors.html">Sponsors:</a>
141
142<div class="sponsbox">
cristyec6b4752011-01-08 03:16:23 +0000143<div class="sponsor">
144 <a title="Sponsor: Web Hosting" href="http://www.bodhost.com/hosting.html">Web Hosting</a><!-- 201104010090 -->
cristy73fd1cd2010-09-12 19:14:25 +0000145</div>
146<div class="sponsor">
cristy7d52cd62010-10-01 17:26:59 +0000147 <a title="Sponsor: Druckerei" href="http://print24.com/de/">Druckerei</a><!-- 201110010720 -->
148</div>
149<div class="sponsor">
cristyc5baf4f2010-08-31 15:05:33 +0000150 <a title="Sponsor: Image Converter" href="http://www.batchphoto.com">Image Converter</a><!-- 201103010900 Bits Coffee-->
151</div>
152<div class="sponsor">
cristy851dbce2010-08-06 21:40:00 +0000153 <a title="Sponsor: Flyer drucken" href="http://www.online-druck.biz">Flyer drucken</a><!-- 201109010900 Floeter-->
154</div>
cristyec6b4752011-01-08 03:16:23 +0000155<div class="sponsor">
cristy7a40ba82011-01-08 20:31:18 +0000156 <a title="Sponsor: alaTest.com" href="http://alatest.com">alaTest.com</a><!-- 20110801000300 -->
cristyec6b4752011-01-08 03:16:23 +0000157</div>
cristy10c87152010-06-26 16:12:21 +0000158</div>
cristyce69bb02010-07-27 19:49:46 +0000159</div>
160</div>
cristy10c87152010-06-26 16:12:21 +0000161
cristyce69bb02010-07-27 19:49:46 +0000162<div class="eastbar">
163 <script type="text/javascript">
164 <!--
165 google_ad_client = "pub-3129977114552745";
cristyce69bb02010-07-27 19:49:46 +0000166 google_ad_slot = "0574824969";
167 google_ad_width = 160;
168 google_ad_height = 600;
169 //-->
170 </script>
171 <script type="text/javascript"
172 src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
173 </script>
cristy10c87152010-06-26 16:12:21 +0000174</div>
175
176<div class="main">
177
cristy307ba182010-12-25 01:00:34 +0000178<h1>Module image-view
179 Methods</h1>
cristyce66ab12010-10-21 23:36:32 +0000180<p class="navigation-index">[<a href="#CloneImageView">CloneImageView</a> &bull; <a href="#DestroyImageView">DestroyImageView</a> &bull; <a href="#DuplexTransferImageViewIterator">DuplexTransferImageViewIterator</a> &bull; <a href="#GetImageViewAuthenticIndexes">GetImageViewAuthenticIndexes</a> &bull; <a href="#GetImageViewAuthenticPixels">GetImageViewAuthenticPixels</a> &bull; <a href="#GetImageViewException">GetImageViewException</a> &bull; <a href="#GetImageViewExtent">GetImageViewExtent</a> &bull; <a href="#GetImageViewImage">GetImageViewImage</a> &bull; <a href="#GetImageViewIterator">GetImageViewIterator</a> &bull; <a href="#GetImageViewVirtualIndexes">GetImageViewVirtualIndexes</a> &bull; <a href="#GetImageViewVirtualPixels">GetImageViewVirtualPixels</a> &bull; <a href="#IsImageView">IsImageView</a> &bull; <a href="#NewImageView">NewImageView</a> &bull; <a href="#NewImageViewRegion">NewImageViewRegion</a> &bull; <a href="#SetImageViewDescription">SetImageViewDescription</a> &bull; <a href="#SetImageViewIterator">SetImageViewIterator</a> &bull; <a href="#SetImageViewThreads">SetImageViewThreads</a> &bull; <a href="#TransferImageViewIterator">TransferImageViewIterator</a> &bull; <a href="#UpdateImageViewIterator">UpdateImageViewIterator</a>]</p>
cristy10c87152010-06-26 16:12:21 +0000181
cristy7a40ba82011-01-08 20:31:18 +0000182<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
183_8c.html" id="CloneImageView">CloneImageView</a></h2>
cristy10c87152010-06-26 16:12:21 +0000184<div class="doc-section">
185
cristy7a40ba82011-01-08 20:31:18 +0000186<p>CloneImageView() makes a copy of the specified image view.</p>
cristy10c87152010-06-26 16:12:21 +0000187
188<p>The format of the CloneImageView method is:</p>
189
190<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000191 ImageView *CloneImageView(const ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000192</pre>
193
cristy7a40ba82011-01-08 20:31:18 +0000194<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000195
cristy73b7d4c2010-06-27 00:31:00 +0000196<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000197<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000198
199 </div>
cristy7a40ba82011-01-08 20:31:18 +0000200<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
201_8c.html" id="DestroyImageView">DestroyImageView</a></h2>
cristy10c87152010-06-26 16:12:21 +0000202<div class="doc-section">
203
cristy7a40ba82011-01-08 20:31:18 +0000204<p>DestroyImageView() deallocates memory associated with a image view.</p>
cristy10c87152010-06-26 16:12:21 +0000205
206<p>The format of the DestroyImageView method is:</p>
207
208<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000209 ImageView *DestroyImageView(ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000210</pre>
211
cristy7a40ba82011-01-08 20:31:18 +0000212<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000213
cristy73b7d4c2010-06-27 00:31:00 +0000214<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000215<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000216
217 </div>
cristy7a40ba82011-01-08 20:31:18 +0000218<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
219_8c.html" id="DuplexTransferImageViewIterator">DuplexTransferImageViewIterator</a></h2>
cristy10c87152010-06-26 16:12:21 +0000220<div class="doc-section">
221
cristy7a40ba82011-01-08 20:31:18 +0000222<p>DuplexTransferImageViewIterator() iterates over three image views in parallel and calls your transfer method for each scanline of the view. The source and duplex pixel extent is not confined to the image canvas-- that is you can include negative offsets or widths or heights that exceed the image dimension. However, the destination image view is confined to the image canvas-- that is no negative offsets or widths or heights that exceed the image dimension are permitted.</p>
cristy10c87152010-06-26 16:12:21 +0000223
cristyd6dfc0d2010-06-27 19:30:49 +0000224<p>The callback signature is:</p>
225
226<pre class="text">
227 MagickBooleanType DuplexTransferImageViewMethod(const ImageView *source,
228 const ImageView *duplex,ImageView *destination,const ssize_t y,
229 const int thread_id,void *context)
230</pre>
231
cristy73b7d4c2010-06-27 00:31:00 +0000232<p>Use this pragma if the view is not single threaded:</p>
cristy10c87152010-06-26 16:12:21 +0000233
234<pre class="text">
235 #pragma omp critical
236</pre>
237
cristy7a40ba82011-01-08 20:31:18 +0000238<p>to define a section of code in your callback transfer method that must be executed by a single thread at a time.</p>
cristy10c87152010-06-26 16:12:21 +0000239
240<p>The format of the DuplexTransferImageViewIterator method is:</p>
241
242<pre class="code">
243 MagickBooleanType DuplexTransferImageViewIterator(ImageView *source,
244 ImageView *duplex,ImageView *destination,
245 DuplexTransferImageViewMethod transfer,void *context)
246</pre>
247
cristy7a40ba82011-01-08 20:31:18 +0000248<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000249
250<h5>source</h5>
cristy7a40ba82011-01-08 20:31:18 +0000251<p>the source image view.</p>
cristy10c87152010-06-26 16:12:21 +0000252
253<h5>duplex</h5>
cristy7a40ba82011-01-08 20:31:18 +0000254<p>the duplex image view.</p>
cristy10c87152010-06-26 16:12:21 +0000255
256<h5>destination</h5>
cristy7a40ba82011-01-08 20:31:18 +0000257<p>the destination image view.</p>
cristy10c87152010-06-26 16:12:21 +0000258
259<h5>transfer</h5>
cristy7a40ba82011-01-08 20:31:18 +0000260<p>the transfer callback method.</p>
cristy10c87152010-06-26 16:12:21 +0000261
262<h5>context</h5>
cristy7a40ba82011-01-08 20:31:18 +0000263<p>the user defined context.</p>
cristy10c87152010-06-26 16:12:21 +0000264
265 </div>
cristy7a40ba82011-01-08 20:31:18 +0000266<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
267_8c.html" id="GetImageViewAuthenticIndexes">GetImageViewAuthenticIndexes</a></h2>
cristy73b7d4c2010-06-27 00:31:00 +0000268<div class="doc-section">
269
cristy7a40ba82011-01-08 20:31:18 +0000270<p>GetImageViewAuthenticIndexes() returns the image view authentic indexes.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000271
272<p>The format of the GetImageViewAuthenticPixels method is:</p>
273
274<pre class="code">
275 IndexPacket *GetImageViewAuthenticIndexes(const ImageView *image_view)
276</pre>
277
cristy7a40ba82011-01-08 20:31:18 +0000278<p>A description of each parameter follows:</p>
cristy73b7d4c2010-06-27 00:31:00 +0000279
280<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000281<p>the image view.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000282
283 </div>
cristy7a40ba82011-01-08 20:31:18 +0000284<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
285_8c.html" id="GetImageViewAuthenticPixels">GetImageViewAuthenticPixels</a></h2>
cristy73b7d4c2010-06-27 00:31:00 +0000286<div class="doc-section">
287
cristy7a40ba82011-01-08 20:31:18 +0000288<p>GetImageViewAuthenticPixels() returns the image view authentic pixels.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000289
290<p>The format of the GetImageViewAuthenticPixels method is:</p>
291
292<pre class="code">
293 PixelPacket *GetImageViewAuthenticPixels(const ImageView *image_view)
294</pre>
295
cristy7a40ba82011-01-08 20:31:18 +0000296<p>A description of each parameter follows:</p>
cristy73b7d4c2010-06-27 00:31:00 +0000297
298<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000299<p>the image view.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000300
301 </div>
cristy7a40ba82011-01-08 20:31:18 +0000302<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
303_8c.html" id="GetImageViewException">GetImageViewException</a></h2>
cristy10c87152010-06-26 16:12:21 +0000304<div class="doc-section">
305
cristy7a40ba82011-01-08 20:31:18 +0000306<p>GetImageViewException() returns the severity, reason, and description of any error that occurs when utilizing a image view.</p>
cristy10c87152010-06-26 16:12:21 +0000307
308<p>The format of the GetImageViewException method is:</p>
309
310<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000311 char *GetImageViewException(const PixelImage *image_view,
cristy10c87152010-06-26 16:12:21 +0000312 ExceptionType *severity)
313</pre>
314
cristy7a40ba82011-01-08 20:31:18 +0000315<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000316
cristy73b7d4c2010-06-27 00:31:00 +0000317<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000318<p>the pixel image_view.</p>
cristy10c87152010-06-26 16:12:21 +0000319
320<h5>severity</h5>
cristy7a40ba82011-01-08 20:31:18 +0000321<p>the severity of the error is returned here.</p>
cristy10c87152010-06-26 16:12:21 +0000322
323 </div>
cristy7a40ba82011-01-08 20:31:18 +0000324<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
325_8c.html" id="GetImageViewExtent">GetImageViewExtent</a></h2>
cristy10c87152010-06-26 16:12:21 +0000326<div class="doc-section">
327
cristy7a40ba82011-01-08 20:31:18 +0000328<p>GetImageViewExtent() returns the image view extent.</p>
cristy10c87152010-06-26 16:12:21 +0000329
cristyc3ebda22010-06-27 17:11:57 +0000330<p>The format of the GetImageViewExtent method is:</p>
cristy10c87152010-06-26 16:12:21 +0000331
332<pre class="code">
cristyc3ebda22010-06-27 17:11:57 +0000333 RectangleInfo GetImageViewExtent(const ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000334</pre>
335
cristy7a40ba82011-01-08 20:31:18 +0000336<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000337
cristy73b7d4c2010-06-27 00:31:00 +0000338<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000339<p>the image view.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000340
341 </div>
cristy7a40ba82011-01-08 20:31:18 +0000342<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
343_8c.html" id="GetImageViewImage">GetImageViewImage</a></h2>
cristy73b7d4c2010-06-27 00:31:00 +0000344<div class="doc-section">
345
cristy7a40ba82011-01-08 20:31:18 +0000346<p>GetImageViewImage() returns the image associated with the image view.</p>
cristy73b7d4c2010-06-27 00:31:00 +0000347
348<p>The format of the GetImageViewImage method is:</p>
349
350<pre class="code">
351 MagickCore *GetImageViewImage(const ImageView *image_view)
352</pre>
353
cristy7a40ba82011-01-08 20:31:18 +0000354<p>A description of each parameter follows:</p>
cristy73b7d4c2010-06-27 00:31:00 +0000355
356<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000357<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000358
359 </div>
cristy7a40ba82011-01-08 20:31:18 +0000360<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
361_8c.html" id="GetImageViewIterator">GetImageViewIterator</a></h2>
cristy10c87152010-06-26 16:12:21 +0000362<div class="doc-section">
363
cristy7a40ba82011-01-08 20:31:18 +0000364<p>GetImageViewIterator() iterates over the image view in parallel and calls your get method for each scanline of the view. The pixel extent is not confined to the image canvas-- that is you can include negative offsets or widths or heights that exceed the image dimension. Any updates to the pixels in your callback are ignored.</p>
cristy10c87152010-06-26 16:12:21 +0000365
cristyd6dfc0d2010-06-27 19:30:49 +0000366<p>The callback signature is:</p>
367
368<pre class="text">
369 MagickBooleanType GetImageViewMethod(const ImageView *source,
370 const ssize_t y,const int thread_id,void *context)
371</pre>
372
cristy73b7d4c2010-06-27 00:31:00 +0000373<p>Use this pragma if the view is not single threaded:</p>
cristy10c87152010-06-26 16:12:21 +0000374
375<pre class="text">
376 #pragma omp critical
377</pre>
378
cristy7a40ba82011-01-08 20:31:18 +0000379<p>to define a section of code in your callback get method that must be executed by a single thread at a time.</p>
cristy10c87152010-06-26 16:12:21 +0000380
381<p>The format of the GetImageViewIterator method is:</p>
382
383<pre class="code">
384 MagickBooleanType GetImageViewIterator(ImageView *source,
385 GetImageViewMethod get,void *context)
386</pre>
387
cristy7a40ba82011-01-08 20:31:18 +0000388<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000389
390<h5>source</h5>
cristy7a40ba82011-01-08 20:31:18 +0000391<p>the source image view.</p>
cristy10c87152010-06-26 16:12:21 +0000392
393<h5>get</h5>
cristy7a40ba82011-01-08 20:31:18 +0000394<p>the get callback method.</p>
cristy10c87152010-06-26 16:12:21 +0000395
396<h5>context</h5>
cristy7a40ba82011-01-08 20:31:18 +0000397<p>the user defined context.</p>
cristy10c87152010-06-26 16:12:21 +0000398
399 </div>
cristy7a40ba82011-01-08 20:31:18 +0000400<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
401_8c.html" id="GetImageViewVirtualIndexes">GetImageViewVirtualIndexes</a></h2>
cristy10c87152010-06-26 16:12:21 +0000402<div class="doc-section">
403
cristy7a40ba82011-01-08 20:31:18 +0000404<p>GetImageViewVirtualIndexes() returns the image view virtual indexes.</p>
cristy10c87152010-06-26 16:12:21 +0000405
cristy73b7d4c2010-06-27 00:31:00 +0000406<p>The format of the GetImageViewVirtualIndexes method is:</p>
cristy10c87152010-06-26 16:12:21 +0000407
408<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000409 const IndexPacket *GetImageViewVirtualIndexes(
410 const ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000411</pre>
412
cristy7a40ba82011-01-08 20:31:18 +0000413<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000414
cristy73b7d4c2010-06-27 00:31:00 +0000415<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000416<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000417
418 </div>
cristy7a40ba82011-01-08 20:31:18 +0000419<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
420_8c.html" id="GetImageViewVirtualPixels">GetImageViewVirtualPixels</a></h2>
cristy10c87152010-06-26 16:12:21 +0000421<div class="doc-section">
422
cristy7a40ba82011-01-08 20:31:18 +0000423<p>GetImageViewVirtualPixels() returns the image view virtual pixels.</p>
cristy10c87152010-06-26 16:12:21 +0000424
cristy73b7d4c2010-06-27 00:31:00 +0000425<p>The format of the GetImageViewVirtualPixels method is:</p>
cristy10c87152010-06-26 16:12:21 +0000426
427<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000428 const PixelPacket *GetImageViewVirtualPixels(const ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000429</pre>
430
cristy7a40ba82011-01-08 20:31:18 +0000431<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000432
cristy73b7d4c2010-06-27 00:31:00 +0000433<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000434<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000435
436 </div>
cristy7a40ba82011-01-08 20:31:18 +0000437<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
438_8c.html" id="IsImageView">IsImageView</a></h2>
cristy10c87152010-06-26 16:12:21 +0000439<div class="doc-section">
440
cristy7a40ba82011-01-08 20:31:18 +0000441<p>IsImageView() returns MagickTrue if the the parameter is verified as a image view object.</p>
cristy10c87152010-06-26 16:12:21 +0000442
443<p>The format of the IsImageView method is:</p>
444
445<pre class="code">
cristy73b7d4c2010-06-27 00:31:00 +0000446 MagickBooleanType IsImageView(const ImageView *image_view)
cristy10c87152010-06-26 16:12:21 +0000447</pre>
448
cristy7a40ba82011-01-08 20:31:18 +0000449<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000450
cristy73b7d4c2010-06-27 00:31:00 +0000451<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000452<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000453
454 </div>
cristy7a40ba82011-01-08 20:31:18 +0000455<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
456_8c.html" id="NewImageView">NewImageView</a></h2>
cristy10c87152010-06-26 16:12:21 +0000457<div class="doc-section">
458
cristy7a40ba82011-01-08 20:31:18 +0000459<p>NewImageView() returns a image view required for all other methods in the Image View API.</p>
cristy10c87152010-06-26 16:12:21 +0000460
461<p>The format of the NewImageView method is:</p>
462
463<pre class="code">
464 ImageView *NewImageView(MagickCore *wand)
465</pre>
466
cristy7a40ba82011-01-08 20:31:18 +0000467<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000468
469<h5>wand</h5>
cristy7a40ba82011-01-08 20:31:18 +0000470<p>the wand.</p>
cristy10c87152010-06-26 16:12:21 +0000471
472 </div>
cristy7a40ba82011-01-08 20:31:18 +0000473<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
474_8c.html" id="NewImageViewRegion">NewImageViewRegion</a></h2>
cristy10c87152010-06-26 16:12:21 +0000475<div class="doc-section">
476
cristy7a40ba82011-01-08 20:31:18 +0000477<p>NewImageViewRegion() returns a image view required for all other methods in the Image View API.</p>
cristy10c87152010-06-26 16:12:21 +0000478
479<p>The format of the NewImageViewRegion method is:</p>
480
481<pre class="code">
482 ImageView *NewImageViewRegion(MagickCore *wand,const ssize_t x,
483 const ssize_t y,const size_t width,const size_t height)
484</pre>
485
cristy7a40ba82011-01-08 20:31:18 +0000486<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000487
488<h5>wand</h5>
cristy7a40ba82011-01-08 20:31:18 +0000489<p>the magick wand.</p>
cristy10c87152010-06-26 16:12:21 +0000490
491<h5>x,y,columns,rows</h5>
cristy7a40ba82011-01-08 20:31:18 +0000492<p>These values define the perimeter of a extent of pixel_wands view.</p>
cristy10c87152010-06-26 16:12:21 +0000493
494 </div>
cristy7a40ba82011-01-08 20:31:18 +0000495<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
496_8c.html" id="SetImageViewDescription">SetImageViewDescription</a></h2>
cristyd6dfc0d2010-06-27 19:30:49 +0000497<div class="doc-section">
498
cristy7a40ba82011-01-08 20:31:18 +0000499<p>SetImageViewDescription() associates a description with an image view.</p>
cristyd6dfc0d2010-06-27 19:30:49 +0000500
501<p>The format of the SetImageViewDescription method is:</p>
502
503<pre class="code">
504 void SetImageViewDescription(ImageView *image_view,
505 const char *description)
506</pre>
507
cristy7a40ba82011-01-08 20:31:18 +0000508<p>A description of each parameter follows:</p>
cristyd6dfc0d2010-06-27 19:30:49 +0000509
510<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000511<p>the image view.</p>
cristyd6dfc0d2010-06-27 19:30:49 +0000512
513<h5>description</h5>
cristy7a40ba82011-01-08 20:31:18 +0000514<p>the image view description.</p>
cristyd6dfc0d2010-06-27 19:30:49 +0000515
516 </div>
cristy7a40ba82011-01-08 20:31:18 +0000517<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
518_8c.html" id="SetImageViewIterator">SetImageViewIterator</a></h2>
cristy10c87152010-06-26 16:12:21 +0000519<div class="doc-section">
520
cristy7a40ba82011-01-08 20:31:18 +0000521<p>SetImageViewIterator() iterates over the image view in parallel and calls your set method for each scanline of the view. The pixel extent is confined to the image canvas-- that is no negative offsets or widths or heights that exceed the image dimension. The pixels are initiallly undefined and any settings you make in the callback method are automagically synced back to your image.</p>
cristy10c87152010-06-26 16:12:21 +0000522
cristyd6dfc0d2010-06-27 19:30:49 +0000523<p>The callback signature is:</p>
524
525<pre class="text">
526 MagickBooleanType SetImageViewMethod(ImageView *destination,
527 const ssize_t y,const int thread_id,void *context)
528</pre>
529
cristy73b7d4c2010-06-27 00:31:00 +0000530<p>Use this pragma if the view is not single threaded:</p>
cristy10c87152010-06-26 16:12:21 +0000531
532<pre class="text">
533 #pragma omp critical
534</pre>
535
cristy7a40ba82011-01-08 20:31:18 +0000536<p>to define a section of code in your callback set method that must be executed by a single thread at a time.</p>
cristy10c87152010-06-26 16:12:21 +0000537
538<p>The format of the SetImageViewIterator method is:</p>
539
540<pre class="code">
541 MagickBooleanType SetImageViewIterator(ImageView *destination,
542 SetImageViewMethod set,void *context)
543</pre>
544
cristy7a40ba82011-01-08 20:31:18 +0000545<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000546
547<h5>destination</h5>
cristy7a40ba82011-01-08 20:31:18 +0000548<p>the image view.</p>
cristy10c87152010-06-26 16:12:21 +0000549
550<h5>set</h5>
cristy7a40ba82011-01-08 20:31:18 +0000551<p>the set callback method.</p>
cristy10c87152010-06-26 16:12:21 +0000552
553<h5>context</h5>
cristy7a40ba82011-01-08 20:31:18 +0000554<p>the user defined context.</p>
cristy10c87152010-06-26 16:12:21 +0000555
556 </div>
cristy7a40ba82011-01-08 20:31:18 +0000557<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
558_8c.html" id="SetImageViewThreads">SetImageViewThreads</a></h2>
cristyce66ab12010-10-21 23:36:32 +0000559<div class="doc-section">
560
cristy7a40ba82011-01-08 20:31:18 +0000561<p>SetImageViewThreads() sets the number of threads in a thread team.</p>
cristyce66ab12010-10-21 23:36:32 +0000562
563<p>The format of the SetImageViewDescription method is:</p>
564
565<pre class="code">
566 void SetImageViewThreads(ImageView *image_view,
567 const size_t number_threads)
568</pre>
569
cristy7a40ba82011-01-08 20:31:18 +0000570<p>A description of each parameter follows:</p>
cristyce66ab12010-10-21 23:36:32 +0000571
572<h5>image_view</h5>
cristy7a40ba82011-01-08 20:31:18 +0000573<p>the image view.</p>
cristyce66ab12010-10-21 23:36:32 +0000574
575<h5>number_threads</h5>
cristy7a40ba82011-01-08 20:31:18 +0000576<p>the number of threads in a thread team.</p>
cristyce66ab12010-10-21 23:36:32 +0000577
578 </div>
cristy7a40ba82011-01-08 20:31:18 +0000579<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
580_8c.html" id="TransferImageViewIterator">TransferImageViewIterator</a></h2>
cristy10c87152010-06-26 16:12:21 +0000581<div class="doc-section">
582
cristy7a40ba82011-01-08 20:31:18 +0000583<p>TransferImageViewIterator() iterates over two image views in parallel and calls your transfer method for each scanline of the view. The source pixel extent is not confined to the image canvas-- that is you can include negative offsets or widths or heights that exceed the image dimension. However, the destination image view is confined to the image canvas-- that is no negative offsets or widths or heights that exceed the image dimension are permitted.</p>
cristy10c87152010-06-26 16:12:21 +0000584
cristyd6dfc0d2010-06-27 19:30:49 +0000585<p>The callback signature is:</p>
586
587<pre class="text">
588 MagickBooleanType TransferImageViewMethod(const ImageView *source,
589 ImageView *destination,const ssize_t y,const int thread_id,
590 void *context)
591</pre>
592
cristy73b7d4c2010-06-27 00:31:00 +0000593<p>Use this pragma if the view is not single threaded:</p>
cristy10c87152010-06-26 16:12:21 +0000594
595<pre class="text">
596 #pragma omp critical
597</pre>
598
cristy7a40ba82011-01-08 20:31:18 +0000599<p>to define a section of code in your callback transfer method that must be executed by a single thread at a time.</p>
cristy10c87152010-06-26 16:12:21 +0000600
601<p>The format of the TransferImageViewIterator method is:</p>
602
603<pre class="code">
604 MagickBooleanType TransferImageViewIterator(ImageView *source,
605 ImageView *destination,TransferImageViewMethod transfer,void *context)
606</pre>
607
cristy7a40ba82011-01-08 20:31:18 +0000608<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000609
610<h5>source</h5>
cristy7a40ba82011-01-08 20:31:18 +0000611<p>the source image view.</p>
cristy10c87152010-06-26 16:12:21 +0000612
613<h5>destination</h5>
cristy7a40ba82011-01-08 20:31:18 +0000614<p>the destination image view.</p>
cristy10c87152010-06-26 16:12:21 +0000615
616<h5>transfer</h5>
cristy7a40ba82011-01-08 20:31:18 +0000617<p>the transfer callback method.</p>
cristy10c87152010-06-26 16:12:21 +0000618
619<h5>context</h5>
cristy7a40ba82011-01-08 20:31:18 +0000620<p>the user defined context.</p>
cristy10c87152010-06-26 16:12:21 +0000621
622 </div>
cristy7a40ba82011-01-08 20:31:18 +0000623<h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
624_8c.html" id="UpdateImageViewIterator">UpdateImageViewIterator</a></h2>
cristy10c87152010-06-26 16:12:21 +0000625<div class="doc-section">
626
cristy7a40ba82011-01-08 20:31:18 +0000627<p>UpdateImageViewIterator() iterates over the image view in parallel and calls your update method for each scanline of the view. The pixel extent is confined to the image canvas-- that is no negative offsets or widths or heights that exceed the image dimension are permitted. Updates to pixels in your callback are automagically synced back to the image.</p>
cristy10c87152010-06-26 16:12:21 +0000628
cristyd6dfc0d2010-06-27 19:30:49 +0000629<p>The callback signature is:</p>
630
631<pre class="text">
632 MagickBooleanType UpdateImageViewMethod(ImageView *source,
633 const ssize_t y,const int thread_id,void *context)
634</pre>
635
cristy73b7d4c2010-06-27 00:31:00 +0000636<p>Use this pragma if the view is not single threaded:</p>
cristy10c87152010-06-26 16:12:21 +0000637
638<pre class="text">
639 #pragma omp critical
640</pre>
641
cristy7a40ba82011-01-08 20:31:18 +0000642<p>to define a section of code in your callback update method that must be executed by a single thread at a time.</p>
cristy10c87152010-06-26 16:12:21 +0000643
644<p>The format of the UpdateImageViewIterator method is:</p>
645
646<pre class="code">
647 MagickBooleanType UpdateImageViewIterator(ImageView *source,
648 UpdateImageViewMethod update,void *context)
649</pre>
650
cristy7a40ba82011-01-08 20:31:18 +0000651<p>A description of each parameter follows:</p>
cristy10c87152010-06-26 16:12:21 +0000652
653<h5>source</h5>
cristy7a40ba82011-01-08 20:31:18 +0000654<p>the source image view.</p>
cristy10c87152010-06-26 16:12:21 +0000655
656<h5>update</h5>
cristy7a40ba82011-01-08 20:31:18 +0000657<p>the update callback method.</p>
cristy10c87152010-06-26 16:12:21 +0000658
659<h5>context</h5>
cristy7a40ba82011-01-08 20:31:18 +0000660<p>the user defined context.</p>
cristy10c87152010-06-26 16:12:21 +0000661
662 </div>
663
664</div>
665
666<div id="linkbar">
cristyce69bb02010-07-27 19:49:46 +0000667 <span id="linkbar-west">&nbsp;</span>
cristy10c87152010-06-26 16:12:21 +0000668 <span id="linkbar-center">
669 <a href="http://www.imagemagick.org/discourse-server/">Discourse Server</a> &bull;
cristya8902942010-07-30 00:49:52 +0000670 <a href="http://www.imagemagick.org/MagickStudio/scripts/MagickStudio.cgi">Studio</a>
cristy10c87152010-06-26 16:12:21 +0000671 </span>
672 <span id="linkbar-east">&nbsp;</span>
673 </div>
674 <div class="footer">
cristy4103d562010-12-10 01:38:54 +0000675 <span id="footer-west">&copy; 1999-2011 ImageMagick Studio LLC</span>
cristy10c87152010-06-26 16:12:21 +0000676 <span id="footer-east"> <a href="../http://www.imagemagick.org/script/contact.php">Contact the Wizards</a></span>
677 </div>
678 <div style="clear: both; margin: 0; width: 100%; "></div>
cristya8902942010-07-30 00:49:52 +0000679 <script type="text/javascript">
680 var _gaq = _gaq || [];
681 _gaq.push(['_setAccount', 'UA-17690367-1']);
682 _gaq.push(['_trackPageview']);
683
684 (function() {
685 var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
686 ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
687 var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
688 })();
689 </script>
cristy10c87152010-06-26 16:12:21 +0000690</body>
691</html>