]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Fri, 17 Sep 2010 17:35:13 +0000 (17:35 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Fri, 17 Sep 2010 17:35:13 +0000 (17:35 +0000)
wand/deprecate.c
wand/wand-view.c

index 581ba5756404fd60faf3384bfacb95ba2d5f4218..521091e82956c0036eec106ccc8510209152b6d1 100644 (file)
@@ -365,6 +365,9 @@ WandExport MagickBooleanType DuplexTransferPixelViewIterator(
 #endif
   for (y=source->region.y; y < (ssize_t) source->region.height; y++)
   {
+    const int
+      id = GetOpenMPThreadId();
+
     MagickBooleanType
       sync;
 
@@ -380,7 +383,6 @@ WandExport MagickBooleanType DuplexTransferPixelViewIterator(
       *restrict destination_indexes;
 
     register ssize_t
-      id,
       x;
 
     register PixelPacket
@@ -388,7 +390,6 @@ WandExport MagickBooleanType DuplexTransferPixelViewIterator(
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->region.x,y,
       source->region.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -627,6 +628,9 @@ WandExport MagickBooleanType GetPixelViewIterator(PixelView *source,
 #endif
   for (y=source->region.y; y < (ssize_t) source->region.height; y++)
   {
+    const int
+      id = GetOpenMPThreadId();
+
     register const IndexPacket
       *indexes;
 
@@ -634,12 +638,10 @@ WandExport MagickBooleanType GetPixelViewIterator(PixelView *source,
       *pixels;
 
     register ssize_t
-      id,
       x;
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->region.x,y,
       source->region.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -699,12 +701,11 @@ WandExport MagickBooleanType GetPixelViewIterator(PixelView *source,
 */
 WandExport PixelWand **GetPixelViewPixels(const PixelView *pixel_view)
 {
-  ssize_t
-    id;
+  const int
+    id = GetOpenMPThreadId();
 
   assert(pixel_view != (PixelView *) NULL);
   assert(pixel_view->signature == WandSignature);
-  id=GetOpenMPThreadId();
   return(pixel_view->pixel_wands[id]);
 }
 \f
@@ -2577,6 +2578,9 @@ WandExport MagickBooleanType SetPixelViewIterator(PixelView *destination,
 #endif
   for (y=destination->region.y; y < (ssize_t) destination->region.height; y++)
   {
+    const int
+      id = GetOpenMPThreadId();
+
     MagickBooleanType
       sync;
 
@@ -2584,7 +2588,6 @@ WandExport MagickBooleanType SetPixelViewIterator(PixelView *destination,
       *restrict indexes;
 
     register ssize_t
-      id,
       x;
 
     register PixelPacket
@@ -2592,7 +2595,6 @@ WandExport MagickBooleanType SetPixelViewIterator(PixelView *destination,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewAuthenticPixels(destination->view,destination->region.x,
       y,destination->region.width,1,exception);
     if (pixels == (PixelPacket *) NULL)
@@ -2713,6 +2715,9 @@ WandExport MagickBooleanType TransferPixelViewIterator(PixelView *source,
 #endif
   for (y=source->region.y; y < (ssize_t) source->region.height; y++)
   {
+    const int
+      id = GetOpenMPThreadId();
+
     MagickBooleanType
       sync;
 
@@ -2726,7 +2731,6 @@ WandExport MagickBooleanType TransferPixelViewIterator(PixelView *source,
       *restrict destination_indexes;
 
     register ssize_t
-      id,
       x;
 
     register PixelPacket
@@ -2734,7 +2738,6 @@ WandExport MagickBooleanType TransferPixelViewIterator(PixelView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->region.x,y,
       source->region.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -2873,6 +2876,9 @@ WandExport MagickBooleanType UpdatePixelViewIterator(PixelView *source,
 #endif
   for (y=source->region.y; y < (ssize_t) source->region.height; y++)
   {
+    const int
+      id = GetOpenMPThreadId();
+
     register IndexPacket
       *restrict indexes;
 
@@ -2885,7 +2891,6 @@ WandExport MagickBooleanType UpdatePixelViewIterator(PixelView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewAuthenticPixels(source->view,source->region.x,y,
       source->region.width,1,exception);
     if (pixels == (PixelPacket *) NULL)
index 7558837bac364932d9af1204e753d4805735517b..f66ace021e69b405f055071421ceac029d574ca0 100644 (file)
@@ -291,8 +291,8 @@ WandExport MagickBooleanType DuplexTransferWandViewIterator(WandView *source,
 #endif
   for (y=source->extent.y; y < (ssize_t) source->extent.height; y++)
   {
-    int
-      id;
+    const int
+      id = GetOpenMPThreadId();
 
     MagickBooleanType
       sync;
@@ -316,7 +316,6 @@ WandExport MagickBooleanType DuplexTransferWandViewIterator(WandView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->extent.x,y,
       source->extent.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -558,8 +557,8 @@ WandExport MagickBooleanType GetWandViewIterator(WandView *source,
 #endif
   for (y=source->extent.y; y < (ssize_t) source->extent.height; y++)
   {
-    int
-      id;
+    const int
+      id = GetOpenMPThreadId();
 
     register const IndexPacket
       *indexes;
@@ -572,7 +571,6 @@ WandExport MagickBooleanType GetWandViewIterator(WandView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->extent.x,y,
       source->extent.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -632,12 +630,11 @@ WandExport MagickBooleanType GetWandViewIterator(WandView *source,
 */
 WandExport PixelWand **GetWandViewPixels(const WandView *wand_view)
 {
-  int
-    id;
+  const int
+    id = GetOpenMPThreadId();
 
   assert(wand_view != (WandView *) NULL);
   assert(wand_view->signature == WandSignature);
-  id=GetOpenMPThreadId();
   return(wand_view->pixel_wands[id]);
 }
 \f
@@ -958,8 +955,8 @@ WandExport MagickBooleanType SetWandViewIterator(WandView *destination,
 #endif
   for (y=destination->extent.y; y < (ssize_t) destination->extent.height; y++)
   {
-    int
-      id;
+    const int
+      id = GetOpenMPThreadId();
 
     MagickBooleanType
       sync;
@@ -975,7 +972,6 @@ WandExport MagickBooleanType SetWandViewIterator(WandView *destination,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewAuthenticPixels(destination->view,destination->extent.x,
       y,destination->extent.width,1,exception);
     if (pixels == (PixelPacket *) NULL)
@@ -1100,8 +1096,8 @@ WandExport MagickBooleanType TransferWandViewIterator(WandView *source,
 #endif
   for (y=source->extent.y; y < (ssize_t) source->extent.height; y++)
   {
-    int
-      id;
+    const int
+      id = GetOpenMPThreadId();
 
     MagickBooleanType
       sync;
@@ -1123,7 +1119,6 @@ WandExport MagickBooleanType TransferWandViewIterator(WandView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewVirtualPixels(source->view,source->extent.x,y,
       source->extent.width,1,source->exception);
     if (pixels == (const PixelPacket *) NULL)
@@ -1265,8 +1260,8 @@ WandExport MagickBooleanType UpdateWandViewIterator(WandView *source,
 #endif
   for (y=source->extent.y; y < (ssize_t) source->extent.height; y++)
   {
-    int
-      id;
+    const int
+      id = GetOpenMPThreadId();
 
     register IndexPacket
       *restrict indexes;
@@ -1279,7 +1274,6 @@ WandExport MagickBooleanType UpdateWandViewIterator(WandView *source,
 
     if (status == MagickFalse)
       continue;
-    id=GetOpenMPThreadId();
     pixels=GetCacheViewAuthenticPixels(source->view,source->extent.x,y,
       source->extent.width,1,exception);
     if (pixels == (PixelPacket *) NULL)