[Pixman] [PATCH] create getter for component alpha

Siarhei Siamashka siarhei.siamashka at gmail.com
Thu Jun 3 13:26:23 PDT 2010


From: Jeff Muizelaar <jmuizelaar at mozilla.com>

This patch comes from the mozilla central tree. See
http://hg.mozilla.org/mozilla-central/rev/89338a224278 for the
original changeset.

Signed-off-by: Jeff Muizelaar <jmuizelaar at mozilla.com>
Signed-off-by: Egor Starkov <egor.starkov at nokia.com>
Signed-off-by: Rami Ylimaki <ext-rami.ylimaki at nokia.com>
Signed-off-by: Siarhei Siamashka <siarhei.siamashka at nokia.com>
---
 pixman/pixman-image.c |    6 ++++++
 pixman/pixman.h       |    1 +
 2 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/pixman/pixman-image.c b/pixman/pixman-image.c
index 6b0dc6d..718c2be 100644
--- a/pixman/pixman-image.c
+++ b/pixman/pixman-image.c
@@ -680,6 +680,12 @@ pixman_image_set_component_alpha   (pixman_image_t *image,
     image_property_changed (image);
 }
 
+PIXMAN_EXPORT pixman_bool_t
+pixman_image_get_component_alpha   (pixman_image_t       *image)
+{
+    return image->common.component_alpha;
+}
+
 PIXMAN_EXPORT void
 pixman_image_set_accessors (pixman_image_t *           image,
                             pixman_read_memory_func_t  read_func,
diff --git a/pixman/pixman.h b/pixman/pixman.h
index 8df5813..9981f0d 100644
--- a/pixman/pixman.h
+++ b/pixman/pixman.h
@@ -779,6 +779,7 @@ void            pixman_image_set_alpha_map           (pixman_image_t
 						      int16_t                       y);
 void            pixman_image_set_component_alpha     (pixman_image_t               *image,
 						      pixman_bool_t                 component_alpha);
+pixman_bool_t   pixman_image_get_component_alpha     (pixman_image_t               *image);
 void		pixman_image_set_accessors	     (pixman_image_t		   *image,
 						      pixman_read_memory_func_t	    read_func,
 						      pixman_write_memory_func_t    write_func);
-- 
1.6.4.4



More information about the Pixman mailing list