]> granicus.if.org Git - imagemagick/blob - www/api/image-view.html
(no commit message)
[imagemagick] / www / api / image-view.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" \r
2   "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">\r
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" dir="ltr">\r
4 <head>\r
5   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>\r
6   <meta name="verify-v1" content="g222frIIxcQTrvDR3NBRUSKP3AnMNoqxOkIniCEkV7U="/>\r
7   <title>ImageMagick: MagickCore, C API for ImageMagick: Image View Methods</title>
8   <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"/>
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 in a variety of formats. Use ImageMagick to scale, rotate, shear, distort and transform images."/>
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:, image, view, methods, ImageMagick, ImageMagic, MagickCore, MagickWand, PerlMagick, Magick++, RMagick, PythonMagick, JMagick, TclMagick, Image, Magick, Magic, Wand, ImageMagickObject, Swiss, Army, Knife, Image, Processing"/>
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-2011 ImageMagick Studio LLC"/>
23   <meta name="Distribution" content="Global"/>
24   <link rel="icon" href="../../images/wand.png"/>
25   <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"/>\r
27   <link rel="stylesheet" href="http://www.google.com/cse/style/look/default.css" type="text/css" />\r
28   <style type="text/css" media="all">\r
29     @import url("../../www/magick.css");\r
30   </style>\r
31   <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>\r
32   <script type="text/javascript" src="../fancybox/jquery.fancybox-1.3.4.pack.js"></script>\r
33   <link rel="stylesheet" type="text/css" href="../fancybox/jquery.fancybox-1.3.4.css" media="screen" />\r
34   <script type="text/javascript">\r
35     $(document).ready(function() {\r
36       $("a[href$=.jpg],a[href$=.png],a[href$=.gif]").fancybox({\r
37         'transitionIn'  : 'elastic',\r
38         'transitionOut' : 'elastic',\r
39         'overlayShow'   : false,\r
40         'opacity'       : true\r
41       });\r
42     });\r
43   </script>\r
44 </head>\r
45 \r
46 <body id="www-imagemagick-org">\r
47 <div class="titlebar">\r
48 <a href="../../index.html">\r
49   <img src="../../images/script.png" alt="[ImageMagick]"\r
50   style="width: 350px; height: 60px; margin: 28px auto; float: left;" /></a>\r
51 <a href="http://www.networkredux.com">\r
52   <img src="../../images/networkredux.png" alt="[sponsor]"\r
53   style="margin-top: 42px; border: 0px; float: left;" /></a>\r
54 <a href="http://www.imagemagick.org/discourse-server/">\r
55   <img src="../../images/logo.jpg" alt=""\r
56   style="width: 114px; height: 118px; border: 0px; float: right;" /></a>\r
57 <a href="../../index.html">\r
58   <img src="../../images/sprite.jpg" alt=""\r
59   style="width: 114px; height: 118px; border: 0px; float: right;" /></a>\r
60 </div>\r
61 \r
62 <div class="westbar">\r
63 \r
64 <div class="menu">
65   <a title="About ImageMagick" href="../../index.html">About ImageMagick</a>
66 </div>
67 <div class="sep"></div>\r
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>\r
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">
106     <a title="Program Interface: Magick++" href="../../www/magick++.html">Magick++</a>
107 </div>
108 <div class="sep"></div>\r
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>\r
128 <div class="menu">
129   <a title="Search" href="../../www/search.html">Search</a>
130 </div>
131 <div class="sep"></div>\r
132 <div class="menu">
133   <a title="Site Map" href="../../www/sitemap.html">Site Map</a>
134 </div>
135 <div  class="sub">
136   <a title="Site Map: Links" href="../../www/links.html">Links</a>
137 </div>
138 <div class="sep"></div>\r
139 <div  class="menu">
140   <a title="Sponsors" href="../../www/sponsors.html">Sponsors:</a>
141
142 <div class="sponsbox">
143 <div class="sponsor">
144   <a title="Sponsor: Web Hosting" href="http://www.bodhost.com/hosting.shtml">Web Hosting</a><!-- 201104010090 -->
145 </div>
146 <div  class="sponsor">
147   <a title="Sponsor: Druckerei" href="http://print24.com/de/">Druckerei</a><!-- 201110010720 -->
148 </div>
149 <div  class="sponsor">
150   <a title="Sponsor: Image Converter" href="http://www.batchphoto.com">Image Converter</a><!-- 201103010900 Bits Coffee-->
151 </div>
152 <div  class="sponsor">
153   <a title="Sponsor: Flyer drucken" href="http://www.online-druck.biz">Flyer drucken</a><!-- 201109010900 Floeter-->
154 </div>
155 <div  class="sponsor">
156    <a title="Sponsor: Free Catalogs" href="http://www.who-sells-it.com/">Free Catalogs</a><!-- 20120801000600 -->
157 </div>
158 </div>
159 </div>
160 </div>\r
161 \r
162 <div class="eastbar">\r
163   <script type="text/javascript">\r
164   <!--\r
165     google_ad_client = "pub-3129977114552745";\r
166     google_ad_slot = "0574824969";\r
167     google_ad_width = 160;\r
168     google_ad_height = 600;\r
169   //-->\r
170   </script>\r
171   <script type="text/javascript"\r
172     src="http://pagead2.googlesyndication.com/pagead/show_ads.js">\r
173   </script>\r
174 </div>\r
175 \r
176 <div class="main">\r
177 \r
178 <h1>Module image-view
179  Methods</h1>
180 <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>
181
182 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
183 _8c.html" id="CloneImageView">CloneImageView</a></h2>
184 <div class="doc-section">
185
186 <p>CloneImageView() makes a copy of the specified image view.</p>
187
188 <p>The format of the CloneImageView method is:</p>
189
190 <pre class="code">
191   ImageView *CloneImageView(const ImageView *image_view)
192 </pre>
193
194 <p>A description of each parameter follows:</p>
195
196 <h5>image_view</h5>
197 <p>the image view.</p>
198
199  </div>
200 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
201 _8c.html" id="DestroyImageView">DestroyImageView</a></h2>
202 <div class="doc-section">
203
204 <p>DestroyImageView() deallocates memory associated with a image view.</p>
205
206 <p>The format of the DestroyImageView method is:</p>
207
208 <pre class="code">
209   ImageView *DestroyImageView(ImageView *image_view)
210 </pre>
211
212 <p>A description of each parameter follows:</p>
213
214 <h5>image_view</h5>
215 <p>the image view.</p>
216
217  </div>
218 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
219 _8c.html" id="DuplexTransferImageViewIterator">DuplexTransferImageViewIterator</a></h2>
220 <div class="doc-section">
221
222 <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>
223
224 <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
232 <p>Use this pragma if the view is not single threaded:</p>
233
234 <pre class="text">
235       #pragma omp critical
236 </pre>
237
238 <p>to define a section of code in your callback transfer method that must be executed by a single thread at a time.</p>
239
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
248 <p>A description of each parameter follows:</p>
249
250 <h5>source</h5>
251 <p>the source image view.</p>
252
253 <h5>duplex</h5>
254 <p>the duplex image view.</p>
255
256 <h5>destination</h5>
257 <p>the destination image view.</p>
258
259 <h5>transfer</h5>
260 <p>the transfer callback method.</p>
261
262 <h5>context</h5>
263 <p>the user defined context.</p>
264
265  </div>
266 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
267 _8c.html" id="GetImageViewAuthenticIndexes">GetImageViewAuthenticIndexes</a></h2>
268 <div class="doc-section">
269
270 <p>GetImageViewAuthenticIndexes() returns the image view authentic indexes.</p>
271
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
278 <p>A description of each parameter follows:</p>
279
280 <h5>image_view</h5>
281 <p>the image view.</p>
282
283  </div>
284 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
285 _8c.html" id="GetImageViewAuthenticPixels">GetImageViewAuthenticPixels</a></h2>
286 <div class="doc-section">
287
288 <p>GetImageViewAuthenticPixels() returns the image view authentic pixels.</p>
289
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
296 <p>A description of each parameter follows:</p>
297
298 <h5>image_view</h5>
299 <p>the image view.</p>
300
301  </div>
302 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
303 _8c.html" id="GetImageViewException">GetImageViewException</a></h2>
304 <div class="doc-section">
305
306 <p>GetImageViewException() returns the severity, reason, and description of any error that occurs when utilizing a image view.</p>
307
308 <p>The format of the GetImageViewException method is:</p>
309
310 <pre class="code">
311   char *GetImageViewException(const PixelImage *image_view,
312     ExceptionType *severity)
313 </pre>
314
315 <p>A description of each parameter follows:</p>
316
317 <h5>image_view</h5>
318 <p>the pixel image_view.</p>
319
320 <h5>severity</h5>
321 <p>the severity of the error is returned here.</p>
322
323  </div>
324 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
325 _8c.html" id="GetImageViewExtent">GetImageViewExtent</a></h2>
326 <div class="doc-section">
327
328 <p>GetImageViewExtent() returns the image view extent.</p>
329
330 <p>The format of the GetImageViewExtent method is:</p>
331
332 <pre class="code">
333   RectangleInfo GetImageViewExtent(const ImageView *image_view)
334 </pre>
335
336 <p>A description of each parameter follows:</p>
337
338 <h5>image_view</h5>
339 <p>the image view.</p>
340
341  </div>
342 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
343 _8c.html" id="GetImageViewImage">GetImageViewImage</a></h2>
344 <div class="doc-section">
345
346 <p>GetImageViewImage() returns the image associated with the image view.</p>
347
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
354 <p>A description of each parameter follows:</p>
355
356 <h5>image_view</h5>
357 <p>the image view.</p>
358
359  </div>
360 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
361 _8c.html" id="GetImageViewIterator">GetImageViewIterator</a></h2>
362 <div class="doc-section">
363
364 <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>
365
366 <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
373 <p>Use this pragma if the view is not single threaded:</p>
374
375 <pre class="text">
376       #pragma omp critical
377 </pre>
378
379 <p>to define a section of code in your callback get method that must be executed by a single thread at a time.</p>
380
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
388 <p>A description of each parameter follows:</p>
389
390 <h5>source</h5>
391 <p>the source image view.</p>
392
393 <h5>get</h5>
394 <p>the get callback method.</p>
395
396 <h5>context</h5>
397 <p>the user defined context.</p>
398
399  </div>
400 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
401 _8c.html" id="GetImageViewVirtualIndexes">GetImageViewVirtualIndexes</a></h2>
402 <div class="doc-section">
403
404 <p>GetImageViewVirtualIndexes() returns the image view virtual indexes.</p>
405
406 <p>The format of the GetImageViewVirtualIndexes method is:</p>
407
408 <pre class="code">
409   const IndexPacket *GetImageViewVirtualIndexes(
410     const ImageView *image_view)
411 </pre>
412
413 <p>A description of each parameter follows:</p>
414
415 <h5>image_view</h5>
416 <p>the image view.</p>
417
418  </div>
419 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
420 _8c.html" id="GetImageViewVirtualPixels">GetImageViewVirtualPixels</a></h2>
421 <div class="doc-section">
422
423 <p>GetImageViewVirtualPixels() returns the image view virtual pixels.</p>
424
425 <p>The format of the GetImageViewVirtualPixels method is:</p>
426
427 <pre class="code">
428   const PixelPacket *GetImageViewVirtualPixels(const ImageView *image_view)
429 </pre>
430
431 <p>A description of each parameter follows:</p>
432
433 <h5>image_view</h5>
434 <p>the image view.</p>
435
436  </div>
437 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
438 _8c.html" id="IsImageView">IsImageView</a></h2>
439 <div class="doc-section">
440
441 <p>IsImageView() returns MagickTrue if the the parameter is verified as a image view object.</p>
442
443 <p>The format of the IsImageView method is:</p>
444
445 <pre class="code">
446   MagickBooleanType IsImageView(const ImageView *image_view)
447 </pre>
448
449 <p>A description of each parameter follows:</p>
450
451 <h5>image_view</h5>
452 <p>the image view.</p>
453
454  </div>
455 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
456 _8c.html" id="NewImageView">NewImageView</a></h2>
457 <div class="doc-section">
458
459 <p>NewImageView() returns a image view required for all other methods in the Image View API.</p>
460
461 <p>The format of the NewImageView method is:</p>
462
463 <pre class="code">
464   ImageView *NewImageView(MagickCore *wand)
465 </pre>
466
467 <p>A description of each parameter follows:</p>
468
469 <h5>wand</h5>
470 <p>the wand.</p>
471
472  </div>
473 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
474 _8c.html" id="NewImageViewRegion">NewImageViewRegion</a></h2>
475 <div class="doc-section">
476
477 <p>NewImageViewRegion() returns a image view required for all other methods in the Image View API.</p>
478
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
486 <p>A description of each parameter follows:</p>
487
488 <h5>wand</h5>
489 <p>the magick wand.</p>
490
491 <h5>x,y,columns,rows</h5>
492 <p>These values define the perimeter of a extent of pixel_wands view.</p>
493
494  </div>
495 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
496 _8c.html" id="SetImageViewDescription">SetImageViewDescription</a></h2>
497 <div class="doc-section">
498
499 <p>SetImageViewDescription() associates a description with an image view.</p>
500
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
508 <p>A description of each parameter follows:</p>
509
510 <h5>image_view</h5>
511 <p>the image view.</p>
512
513 <h5>description</h5>
514 <p>the image view description.</p>
515
516  </div>
517 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
518 _8c.html" id="SetImageViewIterator">SetImageViewIterator</a></h2>
519 <div class="doc-section">
520
521 <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>
522
523 <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
530 <p>Use this pragma if the view is not single threaded:</p>
531
532 <pre class="text">
533       #pragma omp critical
534 </pre>
535
536 <p>to define a section of code in your callback set method that must be executed by a single thread at a time.</p>
537
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
545 <p>A description of each parameter follows:</p>
546
547 <h5>destination</h5>
548 <p>the image view.</p>
549
550 <h5>set</h5>
551 <p>the set callback method.</p>
552
553 <h5>context</h5>
554 <p>the user defined context.</p>
555
556  </div>
557 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
558 _8c.html" id="SetImageViewThreads">SetImageViewThreads</a></h2>
559 <div class="doc-section">
560
561 <p>SetImageViewThreads() sets the number of threads in a thread team.</p>
562
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
570 <p>A description of each parameter follows:</p>
571
572 <h5>image_view</h5>
573 <p>the image view.</p>
574
575 <h5>number_threads</h5>
576 <p>the number of threads in a thread team.</p>
577
578  </div>
579 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
580 _8c.html" id="TransferImageViewIterator">TransferImageViewIterator</a></h2>
581 <div class="doc-section">
582
583 <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>
584
585 <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
593 <p>Use this pragma if the view is not single threaded:</p>
594
595 <pre class="text">
596       #pragma omp critical
597 </pre>
598
599 <p>to define a section of code in your callback transfer method that must be executed by a single thread at a time.</p>
600
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
608 <p>A description of each parameter follows:</p>
609
610 <h5>source</h5>
611 <p>the source image view.</p>
612
613 <h5>destination</h5>
614 <p>the destination image view.</p>
615
616 <h5>transfer</h5>
617 <p>the transfer callback method.</p>
618
619 <h5>context</h5>
620 <p>the user defined context.</p>
621
622  </div>
623 <h2><a href="http://www.wizards-toolkit.org/api/MagickCore/image-view
624 _8c.html" id="UpdateImageViewIterator">UpdateImageViewIterator</a></h2>
625 <div class="doc-section">
626
627 <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>
628
629 <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
636 <p>Use this pragma if the view is not single threaded:</p>
637
638 <pre class="text">
639       #pragma omp critical
640 </pre>
641
642 <p>to define a section of code in your callback update method that must be executed by a single thread at a time.</p>
643
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
651 <p>A description of each parameter follows:</p>
652
653 <h5>source</h5>
654 <p>the source image view.</p>
655
656 <h5>update</h5>
657 <p>the update callback method.</p>
658
659 <h5>context</h5>
660 <p>the user defined context.</p>
661
662  </div>
663 \r
664 </div>\r
665 \r
666 <div id="linkbar">\r
667     <span id="linkbar-west">&nbsp;</span>\r
668     <span id="linkbar-center">\r
669       <a href="http://www.imagemagick.org/discourse-server/">Discourse Server</a> &bull;\r
670       <a href="http://www.imagemagick.org/MagickStudio/scripts/MagickStudio.cgi">Studio</a>\r
671     </span>\r
672     <span id="linkbar-east">&nbsp;</span>\r
673   </div>\r
674   <div class="footer">\r
675     <span id="footer-west">&copy; 1999-2011 ImageMagick Studio LLC</span>\r
676     <span id="footer-east"> <a href="../http://www.imagemagick.org/script/contact.php">Contact the Wizards</a></span>\r
677   </div>\r
678   <div style="clear: both; margin: 0; width: 100%; "></div>\r
679   <script type="text/javascript">\r
680     var _gaq = _gaq || [];\r
681     _gaq.push(['_setAccount', 'UA-17690367-1']);\r
682     _gaq.push(['_trackPageview']);\r
683 \r
684     (function() {\r
685       var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;\r
686       ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';\r
687       var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);\r
688     })();\r
689   </script>\r
690 </body>\r
691 </html>\r