[cairo-commit] cairo/test gradient-alpha-ref.png, 1.1, 1.2 gradient-alpha.c, 1.1, 1.2

Carl Worth commit at pdx.freedesktop.org
Thu Apr 14 14:02:05 PDT 2005


Committed by: cworth

Update of /cvs/cairo/cairo/test
In directory gabe:/tmp/cvs-serv822/test

Modified Files:
	gradient-alpha-ref.png gradient-alpha.c 
Log Message:

        * test/gradient-alpha-ref.png:
        * test/gradient-alpha.c: (draw): Make gradient change color in
        addition to just changing alpha in order to highlight distinction
        between interpolating in premultiplied vs. non-premultiplied
        space.


Index: gradient-alpha-ref.png
===================================================================
RCS file: /cvs/cairo/cairo/test/gradient-alpha-ref.png,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
Binary files /tmp/cvsU0uBjH and /tmp/cvsLnRCki differ

Index: gradient-alpha.c
===================================================================
RCS file: /cvs/cairo/cairo/test/gradient-alpha.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- gradient-alpha.c	14 Apr 2005 16:31:21 -0000	1.1
+++ gradient-alpha.c	14 Apr 2005 21:02:03 -0000	1.2
@@ -36,14 +36,14 @@
 {
     cairo_pattern_t *gradient;
 
-    gradient = cairo_pattern_create_linear (0, 0,
+    gradient = cairo_pattern_create_linear (0, -height,
 					    0, height);
     cairo_pattern_add_color_stop (gradient, 0.0,
-				  .2, .4, .6,
+				  1.0, 0.0, 0.0,
 				  1.0);
     cairo_pattern_add_color_stop (gradient, 1.0,
-				  .2, .4, .6,
-				  0.0);
+				  0.0, 0.0, 1.0,
+				  0.5);
 
     cairo_set_pattern (cr, gradient);
 




More information about the cairo-commit mailing list