[cairo-commit] cairo/test .cvsignore, 1.55, 1.56 Makefile.am, 1.96, 1.97 extend-reflect.c, NONE, 1.1

Billy Biggs commit at pdx.freedesktop.org
Sun Oct 9 14:51:57 PDT 2005


Committed by: vektor

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

Modified Files:
	.cvsignore Makefile.am 
Added Files:
	extend-reflect.c 
Log Message:
2005-10-09  Billy Biggs  <vektor at dumbterm.net>

	* test/Makefile.am: Add a new test to start investigating bug 4183.
	* test/extend-reflect.c (draw), (main): The new test.
	* test/.cvsignore: Ignore the new test.



Index: .cvsignore
===================================================================
RCS file: /cvs/cairo/cairo/test/.cvsignore,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- .cvsignore	8 Oct 2005 18:58:20 -0000	1.55
+++ .cvsignore	9 Oct 2005 21:51:55 -0000	1.56
@@ -17,6 +17,7 @@
 create-from-png-stream
 dash-caps-joins
 dash-offset-negative
+extend-reflect
 fill-and-stroke
 fill-rule
 filter-nearest-offset

Index: Makefile.am
===================================================================
RCS file: /cvs/cairo/cairo/test/Makefile.am,v
retrieving revision 1.96
retrieving revision 1.97
diff -u -d -r1.96 -r1.97
--- Makefile.am	29 Sep 2005 21:31:08 -0000	1.96
+++ Makefile.am	9 Oct 2005 21:51:55 -0000	1.97
@@ -14,6 +14,7 @@
 create-from-png-stream		\
 dash-caps-joins			\
 dash-offset-negative		\
+extend-reflect			\
 fill-and-stroke			\
 fill-rule			\
 filter-nearest-offset		\
@@ -113,6 +114,8 @@
 dash-caps-joins-rgb24-ref.png				\
 dash-offset-negative-ref.png				\
 dash-offset-negative-rgb24-ref.png			\
+extend-reflect-ref.png					\
+extend-reflect-rgb24-ref.png				\
 fill-and-stroke-ref.png					\
 fill-and-stroke-rgb24-ref.png				\
 fill-rule-ref.png					\
@@ -262,6 +265,7 @@
 create_from_png_stream_LDADD = $(LDADDS)
 dash_caps_joins_LDADD = $(LDADDS)
 dash_offset_negative_LDADD = $(LDADDS)
+extend_reflect_LDADD = $(LDADDS)
 fill_and_stroke_LDADD = $(LDADDS)
 fill_rule_LDADD = $(LDADDS)
 filter_nearest_offset_LDADD = $(LDADDS)

--- NEW FILE: extend-reflect.c ---
#include <math.h>
#include "cairo-test.h"
#include <stdio.h>

#define SIZE 400
#define OFFSET 50
const char	png_filename[]	= "romedalen.png";

cairo_test_t test = {
    "extend-reflect",
    "Test CAIRO_EXTEND_REFLECT for surface patterns",
    SIZE, SIZE
};

static cairo_test_status_t
draw (cairo_t *cr, int width, int height)
{
    cairo_pattern_t *pattern;
    cairo_set_source_rgba (cr, 0, 0, 0, 1);
    cairo_rectangle (cr, 0, 0, SIZE, SIZE);
    cairo_fill (cr);

    pattern = cairo_test_create_pattern_from_png (png_filename);
    cairo_pattern_set_extend (pattern, CAIRO_EXTEND_REFLECT);
    cairo_set_source (cr, pattern);
    cairo_pattern_destroy (pattern);

    cairo_paint (cr);

    return CAIRO_TEST_SUCCESS;
}

int
main (void)
{
    return cairo_test (&test, draw);
}



More information about the cairo-commit mailing list