]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Sun, 3 Jul 2011 00:58:03 +0000 (00:58 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Sun, 3 Jul 2011 00:58:03 +0000 (00:58 +0000)
MagickCore/pixel-accessor.h
MagickCore/pixel.h

index a42b43b006e9493ec837bb4a8f79687dbce6370d..c838378ec11596bc1b922cc6d569109c888a1b9b 100644 (file)
@@ -1,12 +1,12 @@
 /*
   Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization
   dedicated to making software imaging solutions freely available.
-  
+
   You may not use this file except in compliance with the License.
   obtain a copy of the License at
-  
+
     http://www.imagemagick.org/script/license.php
-  
+
   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -90,7 +90,7 @@ static inline Quantum GetPixelInfoLuminance(const PixelInfo *pixel_info)
 {
   Quantum
     luminance;
-  
+
 #if !defined(MAGICKCORE_HDRI_SUPPORT)
   luminance=(Quantum) (0.21267*pixel_info->red+0.71516*pixel_info->green+
     0.07217*pixel_info->blue+0.5);
@@ -147,6 +147,12 @@ static inline Quantum GetPixelPacketIntensity(const PixelPacket *pixel)
 #endif
 }
 
+static inline PixelTrait GetPixelTrait(const Image *image,
+  const PixelComponent component)
+{
+  return(image->component_map[component].trait);
+}
+
 static inline Quantum GetPixelY(const Image *image,const Quantum *pixel)
 {
   return(pixel[image->component_map[YPixelComponent].component]);
index 36e94dcb5da807989f450722f5944b25997fdd17..05e59e6f29dccc066df736fee7ee64496300772d 100644 (file)
@@ -58,7 +58,10 @@ typedef enum
 
 typedef enum
 {
-  UndefinedPixelTrait
+  UndefinedPixelTrait,
+  AlphaPixelTrait,
+  IgnorePixelTrait,
+  UnusedPixelTrait
 } PixelTrait;
 
 typedef struct _PixelComponentMap