summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/Makefile.in87
-rw-r--r--test/Makefile.sources3
-rw-r--r--test/cairo-test-constructors.c4
-rw-r--r--test/cairo-test.c3
-rw-r--r--test/cairo-test.h20
-rw-r--r--test/gl-device-release.c182
-rw-r--r--test/invalid-matrix.c4
-rw-r--r--test/pdiff/Makefile.in1
-rw-r--r--test/reference/arc-looping-dash.ref.pngbin502 -> 464 bytes
-rw-r--r--test/reference/bug-source-cu.rgb24.ref.pngbin3211 -> 3211 bytes
-rw-r--r--test/reference/caps-tails-curve.ref.pngbin54750 -> 54314 bytes
-rw-r--r--test/reference/clip-nesting.rgb24.ref.pngbin937 -> 936 bytes
-rw-r--r--test/reference/clip-stroke-unbounded.argb32.ref.pngbin4128 -> 4127 bytes
-rw-r--r--test/reference/clip-stroke-unbounded.rgb24.ref.pngbin3546 -> 3566 bytes
-rw-r--r--test/reference/mask.argb32.ref.pngbin8579 -> 8565 bytes
-rw-r--r--test/reference/mask.rgb24.ref.pngbin7127 -> 7135 bytes
-rw-r--r--test/reference/record-fill-alpha.argb32.ref.pngbin2736 -> 0 bytes
-rw-r--r--test/reference/record-fill-alpha.ref.pngbin2839 -> 2812 bytes
-rw-r--r--test/reference/record-fill-alpha.rgb24.ref.pngbin2736 -> 0 bytes
-rw-r--r--test/reference/record-paint-alpha-clip-mask.argb32.ref.pngbin340 -> 0 bytes
-rw-r--r--test/reference/record-paint-alpha-clip-mask.ref.pngbin333 -> 318 bytes
-rw-r--r--test/reference/record-paint-alpha-clip-mask.rgb24.ref.pngbin340 -> 0 bytes
-rw-r--r--test/reference/record-text-transform.argb32.ref.pngbin5579 -> 0 bytes
-rw-r--r--test/reference/record-text-transform.rgb24.ref.pngbin5579 -> 0 bytes
-rw-r--r--test/reference/record1414x-fill-alpha.argb32.ref.pngbin4129 -> 0 bytes
-rw-r--r--test/reference/record1414x-fill-alpha.ref.pngbin0 -> 4212 bytes
-rw-r--r--test/reference/record1414x-fill-alpha.rgb24.ref.pngbin4129 -> 0 bytes
-rw-r--r--test/reference/record1414x-text-transform.ref.pngbin8706 -> 8365 bytes
-rw-r--r--test/reference/record2x-fill-alpha.argb32.ref.pngbin5715 -> 0 bytes
-rw-r--r--test/reference/record2x-fill-alpha.ref.pngbin0 -> 5950 bytes
-rw-r--r--test/reference/record2x-fill-alpha.rgb24.ref.pngbin5715 -> 0 bytes
-rw-r--r--test/reference/record2x-text-transform.ref.pngbin13476 -> 13072 bytes
-rw-r--r--test/reference/record90-fill-alpha.argb32.ref.pngbin2651 -> 0 bytes
-rw-r--r--test/reference/record90-fill-alpha.ref.pngbin0 -> 2650 bytes
-rw-r--r--test/reference/record90-fill-alpha.rgb24.ref.pngbin2651 -> 0 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip-mask.argb32.ref.pngbin343 -> 0 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip-mask.ref.pngbin0 -> 316 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip-mask.rgb24.ref.pngbin343 -> 0 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip.argb32.ref.pngbin296 -> 0 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip.ref.pngbin0 -> 320 bytes
-rw-r--r--test/reference/record90-paint-alpha-clip.rgb24.ref.pngbin296 -> 0 bytes
-rw-r--r--test/reference/record90-text-transform.argb32.ref.pngbin5811 -> 0 bytes
-rw-r--r--test/reference/record90-text-transform.ref.pngbin0 -> 5481 bytes
-rw-r--r--test/reference/record90-text-transform.rgb24.ref.pngbin5811 -> 0 bytes
-rw-r--r--test/reference/recording-surface-extend-none.argb32.ref.pngbin3051 -> 3153 bytes
-rw-r--r--test/reference/recording-surface-extend-none.rgb24.ref.pngbin3128 -> 3145 bytes
-rw-r--r--test/reference/recording-surface-extend-pad.argb32.ref.pngbin10822 -> 11200 bytes
-rw-r--r--test/reference/recording-surface-extend-pad.rgb24.ref.pngbin12582 -> 12586 bytes
-rw-r--r--test/reference/recording-surface-extend-reflect.argb32.ref.pngbin23518 -> 23967 bytes
-rw-r--r--test/reference/recording-surface-extend-reflect.rgb24.ref.pngbin23881 -> 23930 bytes
-rw-r--r--test/reference/recording-surface-extend-repeat.argb32.ref.pngbin24047 -> 24091 bytes
-rw-r--r--test/reference/recording-surface-extend-repeat.rgb24.ref.pngbin24038 -> 24075 bytes
-rw-r--r--test/reference/recording-surface-over.argb32.ref.pngbin0 -> 3153 bytes
-rw-r--r--test/reference/recording-surface-over.rgb24.ref.pngbin3128 -> 3145 bytes
-rw-r--r--test/reference/recording-surface-source.argb32.ref.pngbin3044 -> 3153 bytes
-rw-r--r--test/reference/recording-surface-source.rgb24.ref.pngbin3133 -> 3146 bytes
-rw-r--r--test/reference/reflected-stroke.ref.pngbin5139 -> 5116 bytes
-rw-r--r--test/reference/rel-path.rgb24.ref.pngbin216 -> 216 bytes
-rw-r--r--test/reference/stroke-clipped.ref.pngbin0 -> 5790 bytes
-rw-r--r--test/reference/xcb-huge-subimage.ref.pngbin0 -> 97 bytes
-rw-r--r--test/stroke-clipped.c54
-rw-r--r--test/xcb-huge-subimage.c81
62 files changed, 415 insertions, 24 deletions
diff --git a/test/Makefile.in b/test/Makefile.in
index cc3b797..18fef07 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -243,8 +243,8 @@ am__cairo_test_suite_SOURCES_DIST = buffer-diff.c cairo-test.c \
rounded-rectangle-fill.c rounded-rectangle-stroke.c sample.c \
scale-down-source-surface-paint.c scale-offset-image.c \
scale-offset-similar.c scale-source-surface-paint.c \
- scaled-font-zero-matrix.c stroke-ctm-caps.c stroke-image.c \
- stroke-open-box.c select-font-face.c \
+ scaled-font-zero-matrix.c stroke-ctm-caps.c stroke-clipped.c \
+ stroke-image.c stroke-open-box.c select-font-face.c \
select-font-no-show-text.c self-copy.c self-copy-overlap.c \
self-intersecting.c set-source.c show-glyphs-advance.c \
show-glyphs-many.c show-text-current-point.c \
@@ -272,15 +272,17 @@ am__cairo_test_suite_SOURCES_DIST = buffer-diff.c cairo-test.c \
unantialiased-shapes.c unbounded-operator.c unclosed-strokes.c \
user-data.c user-font.c user-font-mask.c user-font-proxy.c \
user-font-rescale.c world-map.c white-in-noop.c \
- xcb-huge-image-shm.c xcb-stress-cache.c xcb-snapshot-assert.c \
- xcomposite-projection.c xlib-expose-event.c zero-alpha.c \
- zero-mask.c pthread-same-source.c pthread-show-text.c \
- pthread-similar.c bitmap-font.c ft-font-create-for-ft-face.c \
+ xcb-huge-image-shm.c xcb-huge-subimage.c xcb-stress-cache.c \
+ xcb-snapshot-assert.c xcomposite-projection.c \
+ xlib-expose-event.c zero-alpha.c zero-mask.c \
+ pthread-same-source.c pthread-show-text.c pthread-similar.c \
+ bitmap-font.c ft-font-create-for-ft-face.c \
ft-show-glyphs-positioning.c ft-show-glyphs-table.c \
ft-text-vertical-layout-type1.c \
ft-text-vertical-layout-type3.c ft-text-antialias-none.c \
- gl-surface-source.c quartz-surface-source.c pdf-features.c \
- pdf-mime-data.c pdf-surface-source.c ps-eps.c ps-features.c \
+ gl-device-release.c gl-surface-source.c \
+ quartz-surface-source.c pdf-features.c pdf-mime-data.c \
+ pdf-surface-source.c ps-eps.c ps-features.c \
ps-surface-source.c svg-surface.c svg-clip.c \
svg-surface-source.c xcb-surface-source.c xlib-surface.c \
xlib-surface-source.c get-xrender-format.c multi-page.c \
@@ -301,7 +303,8 @@ am__objects_5 = cairo_test_suite-bitmap-font.$(OBJEXT) \
cairo_test_suite-ft-text-vertical-layout-type3.$(OBJEXT) \
cairo_test_suite-ft-text-antialias-none.$(OBJEXT)
@CAIRO_HAS_FC_FONT_TRUE@@CAIRO_HAS_FT_FONT_TRUE@am__objects_6 = $(am__objects_5)
-am__objects_7 = cairo_test_suite-gl-surface-source.$(OBJEXT)
+am__objects_7 = cairo_test_suite-gl-device-release.$(OBJEXT) \
+ cairo_test_suite-gl-surface-source.$(OBJEXT)
@CAIRO_HAS_GL_SURFACE_TRUE@am__objects_8 = $(am__objects_7)
am__objects_9 = cairo_test_suite-quartz-surface-source.$(OBJEXT)
@CAIRO_HAS_QUARTZ_SURFACE_TRUE@am__objects_10 = $(am__objects_9)
@@ -623,6 +626,7 @@ am__objects_27 = cairo_test_suite-a1-bug.$(OBJEXT) \
cairo_test_suite-scale-source-surface-paint.$(OBJEXT) \
cairo_test_suite-scaled-font-zero-matrix.$(OBJEXT) \
cairo_test_suite-stroke-ctm-caps.$(OBJEXT) \
+ cairo_test_suite-stroke-clipped.$(OBJEXT) \
cairo_test_suite-stroke-image.$(OBJEXT) \
cairo_test_suite-stroke-open-box.$(OBJEXT) \
cairo_test_suite-select-font-face.$(OBJEXT) \
@@ -699,6 +703,7 @@ am__objects_27 = cairo_test_suite-a1-bug.$(OBJEXT) \
cairo_test_suite-world-map.$(OBJEXT) \
cairo_test_suite-white-in-noop.$(OBJEXT) \
cairo_test_suite-xcb-huge-image-shm.$(OBJEXT) \
+ cairo_test_suite-xcb-huge-subimage.$(OBJEXT) \
cairo_test_suite-xcb-stress-cache.$(OBJEXT) \
cairo_test_suite-xcb-snapshot-assert.$(OBJEXT) \
cairo_test_suite-xcomposite-projection.$(OBJEXT) \
@@ -1011,6 +1016,7 @@ libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
+lzo_LIBS = @lzo_LIBS@
mandir = @mandir@
mesa_DIR = @mesa_DIR@
mkdir_p = @mkdir_p@
@@ -1169,8 +1175,8 @@ test_sources = a1-bug.c a1-clip.c a1-fill.c a1-image-sample.c \
rounded-rectangle-fill.c rounded-rectangle-stroke.c sample.c \
scale-down-source-surface-paint.c scale-offset-image.c \
scale-offset-similar.c scale-source-surface-paint.c \
- scaled-font-zero-matrix.c stroke-ctm-caps.c stroke-image.c \
- stroke-open-box.c select-font-face.c \
+ scaled-font-zero-matrix.c stroke-ctm-caps.c stroke-clipped.c \
+ stroke-image.c stroke-open-box.c select-font-face.c \
select-font-no-show-text.c self-copy.c self-copy-overlap.c \
self-intersecting.c set-source.c show-glyphs-advance.c \
show-glyphs-many.c show-text-current-point.c \
@@ -1198,12 +1204,13 @@ test_sources = a1-bug.c a1-clip.c a1-fill.c a1-image-sample.c \
unantialiased-shapes.c unbounded-operator.c unclosed-strokes.c \
user-data.c user-font.c user-font-mask.c user-font-proxy.c \
user-font-rescale.c world-map.c white-in-noop.c \
- xcb-huge-image-shm.c xcb-stress-cache.c xcb-snapshot-assert.c \
- xcomposite-projection.c xlib-expose-event.c zero-alpha.c \
- zero-mask.c $(am__append_1) $(am__append_2) $(am__append_3) \
- $(am__append_4) $(am__append_5) $(am__append_6) \
- $(am__append_7) $(am__append_8) $(am__append_9) \
- $(am__append_10) $(am__append_11) $(am__append_12) $(test)
+ xcb-huge-image-shm.c xcb-huge-subimage.c xcb-stress-cache.c \
+ xcb-snapshot-assert.c xcomposite-projection.c \
+ xlib-expose-event.c zero-alpha.c zero-mask.c $(am__append_1) \
+ $(am__append_2) $(am__append_3) $(am__append_4) \
+ $(am__append_5) $(am__append_6) $(am__append_7) \
+ $(am__append_8) $(am__append_9) $(am__append_10) \
+ $(am__append_11) $(am__append_12) $(test)
pthread_test_sources = \
pthread-same-source.c \
pthread-show-text.c \
@@ -1220,6 +1227,7 @@ ft_font_test_sources = \
ft-text-antialias-none.c
gl_surface_test_sources = \
+ gl-device-release.c \
gl-surface-source.c
quartz_surface_test_sources = quartz-surface-source.c
@@ -1655,6 +1663,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-get-group-target.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-get-path-extents.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-get-xrender-format.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-gl-device-release.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-gl-surface-source.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-glyph-cache-pressure.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-gradient-alpha.Po@am__quote@
@@ -1836,6 +1845,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-source-surface-scale-paint.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-spline-decomposition.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-stride-12-image.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-stroke-clipped.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-stroke-ctm-caps.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-stroke-image.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-stroke-open-box.Po@am__quote@
@@ -1891,6 +1901,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-white-in-noop.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-world-map.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-xcb-huge-image-shm.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-xcb-snapshot-assert.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-xcb-stress-cache.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-xcb-surface-source.Po@am__quote@
@@ -6059,6 +6070,20 @@ cairo_test_suite-stroke-ctm-caps.obj: stroke-ctm-caps.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-stroke-ctm-caps.obj `if test -f 'stroke-ctm-caps.c'; then $(CYGPATH_W) 'stroke-ctm-caps.c'; else $(CYGPATH_W) '$(srcdir)/stroke-ctm-caps.c'; fi`
+cairo_test_suite-stroke-clipped.o: stroke-clipped.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-stroke-clipped.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-stroke-clipped.Tpo -c -o cairo_test_suite-stroke-clipped.o `test -f 'stroke-clipped.c' || echo '$(srcdir)/'`stroke-clipped.c
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-stroke-clipped.Tpo $(DEPDIR)/cairo_test_suite-stroke-clipped.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='stroke-clipped.c' object='cairo_test_suite-stroke-clipped.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-stroke-clipped.o `test -f 'stroke-clipped.c' || echo '$(srcdir)/'`stroke-clipped.c
+
+cairo_test_suite-stroke-clipped.obj: stroke-clipped.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-stroke-clipped.obj -MD -MP -MF $(DEPDIR)/cairo_test_suite-stroke-clipped.Tpo -c -o cairo_test_suite-stroke-clipped.obj `if test -f 'stroke-clipped.c'; then $(CYGPATH_W) 'stroke-clipped.c'; else $(CYGPATH_W) '$(srcdir)/stroke-clipped.c'; fi`
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-stroke-clipped.Tpo $(DEPDIR)/cairo_test_suite-stroke-clipped.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='stroke-clipped.c' object='cairo_test_suite-stroke-clipped.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-stroke-clipped.obj `if test -f 'stroke-clipped.c'; then $(CYGPATH_W) 'stroke-clipped.c'; else $(CYGPATH_W) '$(srcdir)/stroke-clipped.c'; fi`
+
cairo_test_suite-stroke-image.o: stroke-image.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-stroke-image.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-stroke-image.Tpo -c -o cairo_test_suite-stroke-image.o `test -f 'stroke-image.c' || echo '$(srcdir)/'`stroke-image.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-stroke-image.Tpo $(DEPDIR)/cairo_test_suite-stroke-image.Po
@@ -7123,6 +7148,20 @@ cairo_test_suite-xcb-huge-image-shm.obj: xcb-huge-image-shm.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-xcb-huge-image-shm.obj `if test -f 'xcb-huge-image-shm.c'; then $(CYGPATH_W) 'xcb-huge-image-shm.c'; else $(CYGPATH_W) '$(srcdir)/xcb-huge-image-shm.c'; fi`
+cairo_test_suite-xcb-huge-subimage.o: xcb-huge-subimage.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-xcb-huge-subimage.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Tpo -c -o cairo_test_suite-xcb-huge-subimage.o `test -f 'xcb-huge-subimage.c' || echo '$(srcdir)/'`xcb-huge-subimage.c
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Tpo $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='xcb-huge-subimage.c' object='cairo_test_suite-xcb-huge-subimage.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-xcb-huge-subimage.o `test -f 'xcb-huge-subimage.c' || echo '$(srcdir)/'`xcb-huge-subimage.c
+
+cairo_test_suite-xcb-huge-subimage.obj: xcb-huge-subimage.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-xcb-huge-subimage.obj -MD -MP -MF $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Tpo -c -o cairo_test_suite-xcb-huge-subimage.obj `if test -f 'xcb-huge-subimage.c'; then $(CYGPATH_W) 'xcb-huge-subimage.c'; else $(CYGPATH_W) '$(srcdir)/xcb-huge-subimage.c'; fi`
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Tpo $(DEPDIR)/cairo_test_suite-xcb-huge-subimage.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='xcb-huge-subimage.c' object='cairo_test_suite-xcb-huge-subimage.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-xcb-huge-subimage.obj `if test -f 'xcb-huge-subimage.c'; then $(CYGPATH_W) 'xcb-huge-subimage.c'; else $(CYGPATH_W) '$(srcdir)/xcb-huge-subimage.c'; fi`
+
cairo_test_suite-xcb-stress-cache.o: xcb-stress-cache.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-xcb-stress-cache.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-xcb-stress-cache.Tpo -c -o cairo_test_suite-xcb-stress-cache.o `test -f 'xcb-stress-cache.c' || echo '$(srcdir)/'`xcb-stress-cache.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-xcb-stress-cache.Tpo $(DEPDIR)/cairo_test_suite-xcb-stress-cache.Po
@@ -7347,6 +7386,20 @@ cairo_test_suite-ft-text-antialias-none.obj: ft-text-antialias-none.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-ft-text-antialias-none.obj `if test -f 'ft-text-antialias-none.c'; then $(CYGPATH_W) 'ft-text-antialias-none.c'; else $(CYGPATH_W) '$(srcdir)/ft-text-antialias-none.c'; fi`
+cairo_test_suite-gl-device-release.o: gl-device-release.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-gl-device-release.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-gl-device-release.Tpo -c -o cairo_test_suite-gl-device-release.o `test -f 'gl-device-release.c' || echo '$(srcdir)/'`gl-device-release.c
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-gl-device-release.Tpo $(DEPDIR)/cairo_test_suite-gl-device-release.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='gl-device-release.c' object='cairo_test_suite-gl-device-release.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-gl-device-release.o `test -f 'gl-device-release.c' || echo '$(srcdir)/'`gl-device-release.c
+
+cairo_test_suite-gl-device-release.obj: gl-device-release.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-gl-device-release.obj -MD -MP -MF $(DEPDIR)/cairo_test_suite-gl-device-release.Tpo -c -o cairo_test_suite-gl-device-release.obj `if test -f 'gl-device-release.c'; then $(CYGPATH_W) 'gl-device-release.c'; else $(CYGPATH_W) '$(srcdir)/gl-device-release.c'; fi`
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-gl-device-release.Tpo $(DEPDIR)/cairo_test_suite-gl-device-release.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='gl-device-release.c' object='cairo_test_suite-gl-device-release.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-gl-device-release.obj `if test -f 'gl-device-release.c'; then $(CYGPATH_W) 'gl-device-release.c'; else $(CYGPATH_W) '$(srcdir)/gl-device-release.c'; fi`
+
cairo_test_suite-gl-surface-source.o: gl-surface-source.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-gl-surface-source.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-gl-surface-source.Tpo -c -o cairo_test_suite-gl-surface-source.o `test -f 'gl-surface-source.c' || echo '$(srcdir)/'`gl-surface-source.c
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-gl-surface-source.Tpo $(DEPDIR)/cairo_test_suite-gl-surface-source.Po
diff --git a/test/Makefile.sources b/test/Makefile.sources
index fdf262c..1f03885 100644
--- a/test/Makefile.sources
+++ b/test/Makefile.sources
@@ -290,6 +290,7 @@ test_sources = \
scale-source-surface-paint.c \
scaled-font-zero-matrix.c \
stroke-ctm-caps.c \
+ stroke-clipped.c \
stroke-image.c \
stroke-open-box.c \
select-font-face.c \
@@ -366,6 +367,7 @@ test_sources = \
world-map.c \
white-in-noop.c \
xcb-huge-image-shm.c \
+ xcb-huge-subimage.c \
xcb-stress-cache.c \
xcb-snapshot-assert.c \
xcomposite-projection.c \
@@ -389,6 +391,7 @@ ft_font_test_sources = \
ft-text-antialias-none.c
gl_surface_test_sources = \
+ gl-device-release.c \
gl-surface-source.c
quartz_surface_test_sources = quartz-surface-source.c
diff --git a/test/cairo-test-constructors.c b/test/cairo-test-constructors.c
index 5a5fa43..c9b5c76 100644
--- a/test/cairo-test-constructors.c
+++ b/test/cairo-test-constructors.c
@@ -401,6 +401,7 @@ extern void _register_scale_offset_similar (void);
extern void _register_scale_source_surface_paint (void);
extern void _register_scaled_font_zero_matrix (void);
extern void _register_stroke_ctm_caps (void);
+extern void _register_stroke_clipped (void);
extern void _register_stroke_image (void);
extern void _register_stroke_open_box (void);
extern void _register_select_font_face (void);
@@ -488,6 +489,7 @@ extern void _register_world_map_stroke (void);
extern void _register_world_map_fill (void);
extern void _register_white_in_noop (void);
extern void _register_xcb_huge_image_shm (void);
+extern void _register_xcb_huge_subimage (void);
extern void _register_xcb_stress_cache (void);
extern void _register_xcb_snapshot_assert (void);
extern void _register_xcomposite_projection (void);
@@ -920,6 +922,7 @@ _cairo_test_runner_register_tests (void)
_register_scale_source_surface_paint ();
_register_scaled_font_zero_matrix ();
_register_stroke_ctm_caps ();
+ _register_stroke_clipped ();
_register_stroke_image ();
_register_stroke_open_box ();
_register_select_font_face ();
@@ -1007,6 +1010,7 @@ _cairo_test_runner_register_tests (void)
_register_world_map_fill ();
_register_white_in_noop ();
_register_xcb_huge_image_shm ();
+ _register_xcb_huge_subimage ();
_register_xcb_stress_cache ();
_register_xcb_snapshot_assert ();
_register_xcomposite_projection ();
diff --git a/test/cairo-test.c b/test/cairo-test.c
index 3f37147..076b014 100644
--- a/test/cairo-test.c
+++ b/test/cairo-test.c
@@ -35,9 +35,6 @@
#include <stdlib.h>
#include <stdarg.h>
#include <ctype.h>
-#if HAVE_FEENABLEEXCEPT
-#include <fenv.h>
-#endif
#include <assert.h>
#if HAVE_UNISTD_H
#include <unistd.h>
diff --git a/test/cairo-test.h b/test/cairo-test.h
index d41cd29..87ba7df 100644
--- a/test/cairo-test.h
+++ b/test/cairo-test.h
@@ -62,6 +62,26 @@ typedef unsigned __int64 uint64_t;
#endif
+#if HAVE_FENV_H
+# include <fenv.h>
+#endif
+/* The following are optional in C99, so define them if they aren't yet */
+#ifndef FE_DIVBYZERO
+#define FE_DIVBYZERO 0
+#endif
+#ifndef FE_INEXACT
+#define FE_INEXACT 0
+#endif
+#ifndef FE_INVALID
+#define FE_INVALID 0
+#endif
+#ifndef FE_OVERFLOW
+#define FE_OVERFLOW 0
+#endif
+#ifndef FE_UNDERFLOW
+#define FE_UNDERFLOW 0
+#endif
+
#include <math.h>
static inline double
diff --git a/test/gl-device-release.c b/test/gl-device-release.c
new file mode 100644
index 0000000..7f554be
--- /dev/null
+++ b/test/gl-device-release.c
@@ -0,0 +1,182 @@
+/*
+ * Copyright © 2012 Igalia S.L.
+ * Copyright © 2009 Eric Anholt
+ * Copyright © 2009 Chris Wilson
+ * Copyright © 2005 Red Hat, Inc
+ *
+ * Permission to use, copy, modify, distribute, and sell this software
+ * and its documentation for any purpose is hereby granted without
+ * fee, provided that the above copyright notice appear in all copies
+ * and that both that copyright notice and this permission notice
+ * appear in supporting documentation, and that the name of
+ * Chris Wilson not be used in advertising or publicity pertaining to
+ * distribution of the software without specific, written prior
+ * permission. Chris Wilson makes no representations about the
+ * suitability of this software for any purpose. It is provided "as
+ * is" without express or implied warranty.
+ *
+ * IGALIA S.L. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS, IN NO EVENT SHALL CHRIS WILSON BE LIABLE FOR ANY SPECIAL,
+ * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
+ * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
+ * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+ * IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ *
+ * Author: Martin Robinson <mrobinson@igalia.com>
+ */
+
+#include "cairo-test.h"
+#include <cairo-gl.h>
+#include <assert.h>
+
+static Window
+create_test_window (Display *display,
+ GLXContext glx_context,
+ XVisualInfo *visual_info)
+{
+ Colormap colormap;
+ XSetWindowAttributes window_attributes;
+ Window window = None;
+
+ colormap = XCreateColormap (display,
+ RootWindow (display, visual_info->screen),
+ visual_info->visual,
+ AllocNone);
+ window_attributes.colormap = colormap;
+ window_attributes.border_pixel = 0;
+ window = XCreateWindow (display, RootWindow (display, visual_info->screen),
+ -1, -1, 1, 1, 0,
+ visual_info->depth,
+ InputOutput,
+ visual_info->visual,
+ CWBorderPixel | CWColormap, &window_attributes);
+ XFreeColormap (display, colormap);
+
+ XFlush (display);
+ return window;
+}
+
+static cairo_bool_t
+multithread_makecurrent_available (Display *display)
+{
+ const char *extensions = glXQueryExtensionsString (display,
+ DefaultScreen (display));
+ return !! strstr(extensions, "GLX_MESA_multithread_makecurrent");
+}
+
+static void
+draw_to_surface (cairo_surface_t *surface)
+{
+ cairo_t *cr = cairo_create (surface);
+ cairo_paint (cr);
+ cairo_destroy (cr);
+}
+
+static cairo_test_status_t
+preamble (cairo_test_context_t *test_ctx)
+{
+ int rgba_attribs[] = {
+ GLX_RGBA,
+ GLX_RED_SIZE, 1,
+ GLX_GREEN_SIZE, 1,
+ GLX_BLUE_SIZE, 1,
+ GLX_ALPHA_SIZE, 1,
+ GLX_DOUBLEBUFFER,
+ None
+ };
+
+ XVisualInfo *visual_info;
+ GLXContext glx_context;
+ cairo_device_t *device;
+ Display *display;
+ Window test_window;
+ cairo_surface_t *window_surface;
+ cairo_bool_t has_multithread_makecurrent;
+
+ display = XOpenDisplay (NULL);
+ if (display == NULL)
+ return CAIRO_TEST_UNTESTED;
+
+ visual_info = glXChooseVisual (display, DefaultScreen (display), rgba_attribs);
+ if (visual_info == NULL) {
+ XCloseDisplay (display);
+ return CAIRO_TEST_UNTESTED;
+ }
+
+ glx_context = glXCreateContext (display, visual_info, NULL, True);
+ if (glx_context == NULL) {
+ XCloseDisplay (display);
+ return CAIRO_TEST_UNTESTED;
+ }
+
+ test_window = create_test_window (display, glx_context, visual_info);
+ XFree (visual_info);
+ if (test_window == None) {
+ XCloseDisplay (display);
+ return CAIRO_TEST_UNTESTED;
+ }
+
+ has_multithread_makecurrent = multithread_makecurrent_available (display);
+
+ glXMakeCurrent (display, None, None);
+
+ /* Creating the device should actually change the GL context, because of
+ * the creation/activation of a dummy window used for texture surfaces. */
+ device = cairo_glx_device_create (display, glx_context);
+
+ /* It's important that when multithread_makecurrent isn't available the
+ * Cairo backend clears the current context, so that the dummy texture
+ * window is not active while the device is unlocked. */
+ if (has_multithread_makecurrent) {
+ assert (None != glXGetCurrentDrawable ());
+ assert (display == glXGetCurrentDisplay ());
+ assert (glx_context == glXGetCurrentContext ());
+ } else {
+ assert (None == glXGetCurrentDrawable ());
+ assert (None == glXGetCurrentDisplay ());
+ assert (None == glXGetCurrentContext ());
+ }
+
+ window_surface = cairo_gl_surface_create_for_window (device, test_window,
+ 1, 1);
+ assert (cairo_surface_status (window_surface) == CAIRO_STATUS_SUCCESS);
+
+ draw_to_surface (window_surface);
+ if (has_multithread_makecurrent) {
+ assert (test_window == glXGetCurrentDrawable ());
+ assert (display == glXGetCurrentDisplay ());
+ assert (glx_context == glXGetCurrentContext ());
+ } else {
+ assert (None == glXGetCurrentDrawable ());
+ assert (None == glXGetCurrentDisplay ());
+ assert (None == glXGetCurrentContext ());
+ }
+
+ /* In this case, drawing to the window surface will not change the current
+ * GL context, so Cairo setting the current surface and context to none. */
+ glXMakeCurrent (display, test_window, glx_context);
+ draw_to_surface (window_surface);
+ assert (test_window == glXGetCurrentDrawable ());
+ assert (display == glXGetCurrentDisplay ());
+ assert (glx_context == glXGetCurrentContext ());
+
+ /* There should be no context change when destroying the device. */
+ cairo_device_destroy (device);
+ assert (test_window == glXGetCurrentDrawable ());
+ assert (display == glXGetCurrentDisplay ());
+ assert (glx_context == glXGetCurrentContext ());
+
+ glXDestroyContext(display, glx_context);
+ XDestroyWindow (display, test_window);
+ XCloseDisplay (display);
+
+ return CAIRO_TEST_SUCCESS;
+}
+
+CAIRO_TEST (gl_device_creation_changes_context,
+ "Test that using the Cairo GL backend leaves the current GL context in the appropriate state",
+ "gl", /* keywords */
+ NULL, /* requirements */
+ 0, 0,
+ preamble, NULL)
diff --git a/test/invalid-matrix.c b/test/invalid-matrix.c
index 6cfaedf..9bb26be 100644
--- a/test/invalid-matrix.c
+++ b/test/invalid-matrix.c
@@ -33,10 +33,6 @@
#define INFINITY HUGE_VAL
#endif
-#if HAVE_FENV_H
-# include <fenv.h>
-#endif
-
static cairo_test_status_t
draw (cairo_t *cr, int width, int height)
{
diff --git a/test/pdiff/Makefile.in b/test/pdiff/Makefile.in
index 0e41f74..8a1bf8f 100644
--- a/test/pdiff/Makefile.in
+++ b/test/pdiff/Makefile.in
@@ -310,6 +310,7 @@ libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
+lzo_LIBS = @lzo_LIBS@
mandir = @mandir@
mesa_DIR = @mesa_DIR@
mkdir_p = @mkdir_p@
diff --git a/test/reference/arc-looping-dash.ref.png b/test/reference/arc-looping-dash.ref.png
index 6d0c5cf..516e66c 100644
--- a/test/reference/arc-looping-dash.ref.png
+++ b/test/reference/arc-looping-dash.ref.png
Binary files differ
diff --git a/test/reference/bug-source-cu.rgb24.ref.png b/test/reference/bug-source-cu.rgb24.ref.png
index 6cf2b1a..9f2f52c 100644
--- a/test/reference/bug-source-cu.rgb24.ref.png
+++ b/test/reference/bug-source-cu.rgb24.ref.png
Binary files differ
diff --git a/test/reference/caps-tails-curve.ref.png b/test/reference/caps-tails-curve.ref.png
index f23d5dc..ac97c82 100644
--- a/test/reference/caps-tails-curve.ref.png
+++ b/test/reference/caps-tails-curve.ref.png
Binary files differ
diff --git a/test/reference/clip-nesting.rgb24.ref.png b/test/reference/clip-nesting.rgb24.ref.png
index 5247843..c62bf29 100644
--- a/test/reference/clip-nesting.rgb24.ref.png
+++ b/test/reference/clip-nesting.rgb24.ref.png
Binary files differ
diff --git a/test/reference/clip-stroke-unbounded.argb32.ref.png b/test/reference/clip-stroke-unbounded.argb32.ref.png
index 8bf64c1..316cc36 100644
--- a/test/reference/clip-stroke-unbounded.argb32.ref.png
+++ b/test/reference/clip-stroke-unbounded.argb32.ref.png
Binary files differ
diff --git a/test/reference/clip-stroke-unbounded.rgb24.ref.png b/test/reference/clip-stroke-unbounded.rgb24.ref.png
index 2dbe36b..ee4bec4 100644
--- a/test/reference/clip-stroke-unbounded.rgb24.ref.png
+++ b/test/reference/clip-stroke-unbounded.rgb24.ref.png
Binary files differ
diff --git a/test/reference/mask.argb32.ref.png b/test/reference/mask.argb32.ref.png
index d965468..2d740d4 100644
--- a/test/reference/mask.argb32.ref.png
+++ b/test/reference/mask.argb32.ref.png
Binary files differ
diff --git a/test/reference/mask.rgb24.ref.png b/test/reference/mask.rgb24.ref.png
index 0617ec2..12114a7 100644
--- a/test/reference/mask.rgb24.ref.png
+++ b/test/reference/mask.rgb24.ref.png
Binary files differ
diff --git a/test/reference/record-fill-alpha.argb32.ref.png b/test/reference/record-fill-alpha.argb32.ref.png
deleted file mode 100644
index 9de7b50..0000000
--- a/test/reference/record-fill-alpha.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record-fill-alpha.ref.png b/test/reference/record-fill-alpha.ref.png
index 630c024..06a4d55 100644
--- a/test/reference/record-fill-alpha.ref.png
+++ b/test/reference/record-fill-alpha.ref.png
Binary files differ
diff --git a/test/reference/record-fill-alpha.rgb24.ref.png b/test/reference/record-fill-alpha.rgb24.ref.png
deleted file mode 100644
index 9de7b50..0000000
--- a/test/reference/record-fill-alpha.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record-paint-alpha-clip-mask.argb32.ref.png b/test/reference/record-paint-alpha-clip-mask.argb32.ref.png
deleted file mode 100644
index 5054672..0000000
--- a/test/reference/record-paint-alpha-clip-mask.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record-paint-alpha-clip-mask.ref.png b/test/reference/record-paint-alpha-clip-mask.ref.png
index 3bc8cd5..34d3aa6 100644
--- a/test/reference/record-paint-alpha-clip-mask.ref.png
+++ b/test/reference/record-paint-alpha-clip-mask.ref.png
Binary files differ
diff --git a/test/reference/record-paint-alpha-clip-mask.rgb24.ref.png b/test/reference/record-paint-alpha-clip-mask.rgb24.ref.png
deleted file mode 100644
index 5054672..0000000
--- a/test/reference/record-paint-alpha-clip-mask.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record-text-transform.argb32.ref.png b/test/reference/record-text-transform.argb32.ref.png
deleted file mode 100644
index 4603bc5..0000000
--- a/test/reference/record-text-transform.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record-text-transform.rgb24.ref.png b/test/reference/record-text-transform.rgb24.ref.png
deleted file mode 100644
index 4603bc5..0000000
--- a/test/reference/record-text-transform.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record1414x-fill-alpha.argb32.ref.png b/test/reference/record1414x-fill-alpha.argb32.ref.png
deleted file mode 100644
index 545c0da..0000000
--- a/test/reference/record1414x-fill-alpha.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record1414x-fill-alpha.ref.png b/test/reference/record1414x-fill-alpha.ref.png
new file mode 100644
index 0000000..4b4c780
--- /dev/null
+++ b/test/reference/record1414x-fill-alpha.ref.png
Binary files differ
diff --git a/test/reference/record1414x-fill-alpha.rgb24.ref.png b/test/reference/record1414x-fill-alpha.rgb24.ref.png
deleted file mode 100644
index 545c0da..0000000
--- a/test/reference/record1414x-fill-alpha.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record1414x-text-transform.ref.png b/test/reference/record1414x-text-transform.ref.png
index 5727f35..ef3c967 100644
--- a/test/reference/record1414x-text-transform.ref.png
+++ b/test/reference/record1414x-text-transform.ref.png
Binary files differ
diff --git a/test/reference/record2x-fill-alpha.argb32.ref.png b/test/reference/record2x-fill-alpha.argb32.ref.png
deleted file mode 100644
index ce4dab1..0000000
--- a/test/reference/record2x-fill-alpha.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record2x-fill-alpha.ref.png b/test/reference/record2x-fill-alpha.ref.png
new file mode 100644
index 0000000..ae0646e
--- /dev/null
+++ b/test/reference/record2x-fill-alpha.ref.png
Binary files differ
diff --git a/test/reference/record2x-fill-alpha.rgb24.ref.png b/test/reference/record2x-fill-alpha.rgb24.ref.png
deleted file mode 100644
index ce4dab1..0000000
--- a/test/reference/record2x-fill-alpha.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record2x-text-transform.ref.png b/test/reference/record2x-text-transform.ref.png
index 6c21785..ff521ab 100644
--- a/test/reference/record2x-text-transform.ref.png
+++ b/test/reference/record2x-text-transform.ref.png
Binary files differ
diff --git a/test/reference/record90-fill-alpha.argb32.ref.png b/test/reference/record90-fill-alpha.argb32.ref.png
deleted file mode 100644
index afbc68e..0000000
--- a/test/reference/record90-fill-alpha.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-fill-alpha.ref.png b/test/reference/record90-fill-alpha.ref.png
new file mode 100644
index 0000000..a4c4bb8
--- /dev/null
+++ b/test/reference/record90-fill-alpha.ref.png
Binary files differ
diff --git a/test/reference/record90-fill-alpha.rgb24.ref.png b/test/reference/record90-fill-alpha.rgb24.ref.png
deleted file mode 100644
index afbc68e..0000000
--- a/test/reference/record90-fill-alpha.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip-mask.argb32.ref.png b/test/reference/record90-paint-alpha-clip-mask.argb32.ref.png
deleted file mode 100644
index aa94252..0000000
--- a/test/reference/record90-paint-alpha-clip-mask.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip-mask.ref.png b/test/reference/record90-paint-alpha-clip-mask.ref.png
new file mode 100644
index 0000000..03cf805
--- /dev/null
+++ b/test/reference/record90-paint-alpha-clip-mask.ref.png
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip-mask.rgb24.ref.png b/test/reference/record90-paint-alpha-clip-mask.rgb24.ref.png
deleted file mode 100644
index aa94252..0000000
--- a/test/reference/record90-paint-alpha-clip-mask.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip.argb32.ref.png b/test/reference/record90-paint-alpha-clip.argb32.ref.png
deleted file mode 100644
index 15d1a31..0000000
--- a/test/reference/record90-paint-alpha-clip.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip.ref.png b/test/reference/record90-paint-alpha-clip.ref.png
new file mode 100644
index 0000000..ab1fe3c
--- /dev/null
+++ b/test/reference/record90-paint-alpha-clip.ref.png
Binary files differ
diff --git a/test/reference/record90-paint-alpha-clip.rgb24.ref.png b/test/reference/record90-paint-alpha-clip.rgb24.ref.png
deleted file mode 100644
index 15d1a31..0000000
--- a/test/reference/record90-paint-alpha-clip.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-text-transform.argb32.ref.png b/test/reference/record90-text-transform.argb32.ref.png
deleted file mode 100644
index 22f6c1f..0000000
--- a/test/reference/record90-text-transform.argb32.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/record90-text-transform.ref.png b/test/reference/record90-text-transform.ref.png
new file mode 100644
index 0000000..e8fa722
--- /dev/null
+++ b/test/reference/record90-text-transform.ref.png
Binary files differ
diff --git a/test/reference/record90-text-transform.rgb24.ref.png b/test/reference/record90-text-transform.rgb24.ref.png
deleted file mode 100644
index 22f6c1f..0000000
--- a/test/reference/record90-text-transform.rgb24.ref.png
+++ /dev/null
Binary files differ
diff --git a/test/reference/recording-surface-extend-none.argb32.ref.png b/test/reference/recording-surface-extend-none.argb32.ref.png
index c8040da..d69cdc9 100644
--- a/test/reference/recording-surface-extend-none.argb32.ref.png
+++ b/test/reference/recording-surface-extend-none.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-none.rgb24.ref.png b/test/reference/recording-surface-extend-none.rgb24.ref.png
index bd84338..48401f9 100644
--- a/test/reference/recording-surface-extend-none.rgb24.ref.png
+++ b/test/reference/recording-surface-extend-none.rgb24.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-pad.argb32.ref.png b/test/reference/recording-surface-extend-pad.argb32.ref.png
index f1c3d23..31b7005 100644
--- a/test/reference/recording-surface-extend-pad.argb32.ref.png
+++ b/test/reference/recording-surface-extend-pad.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-pad.rgb24.ref.png b/test/reference/recording-surface-extend-pad.rgb24.ref.png
index 4906c8f..06a6ce2 100644
--- a/test/reference/recording-surface-extend-pad.rgb24.ref.png
+++ b/test/reference/recording-surface-extend-pad.rgb24.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-reflect.argb32.ref.png b/test/reference/recording-surface-extend-reflect.argb32.ref.png
index 016bf39..bc1d70f 100644
--- a/test/reference/recording-surface-extend-reflect.argb32.ref.png
+++ b/test/reference/recording-surface-extend-reflect.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-reflect.rgb24.ref.png b/test/reference/recording-surface-extend-reflect.rgb24.ref.png
index 59b58e9..f6f52e7 100644
--- a/test/reference/recording-surface-extend-reflect.rgb24.ref.png
+++ b/test/reference/recording-surface-extend-reflect.rgb24.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-repeat.argb32.ref.png b/test/reference/recording-surface-extend-repeat.argb32.ref.png
index 960bfd2..d95245b 100644
--- a/test/reference/recording-surface-extend-repeat.argb32.ref.png
+++ b/test/reference/recording-surface-extend-repeat.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-extend-repeat.rgb24.ref.png b/test/reference/recording-surface-extend-repeat.rgb24.ref.png
index d49fd12..2d77522 100644
--- a/test/reference/recording-surface-extend-repeat.rgb24.ref.png
+++ b/test/reference/recording-surface-extend-repeat.rgb24.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-over.argb32.ref.png b/test/reference/recording-surface-over.argb32.ref.png
new file mode 100644
index 0000000..d69cdc9
--- /dev/null
+++ b/test/reference/recording-surface-over.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-over.rgb24.ref.png b/test/reference/recording-surface-over.rgb24.ref.png
index bd84338..48401f9 100644
--- a/test/reference/recording-surface-over.rgb24.ref.png
+++ b/test/reference/recording-surface-over.rgb24.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-source.argb32.ref.png b/test/reference/recording-surface-source.argb32.ref.png
index 22c612b..bc6930f 100644
--- a/test/reference/recording-surface-source.argb32.ref.png
+++ b/test/reference/recording-surface-source.argb32.ref.png
Binary files differ
diff --git a/test/reference/recording-surface-source.rgb24.ref.png b/test/reference/recording-surface-source.rgb24.ref.png
index 3481673..b77d6dc 100644
--- a/test/reference/recording-surface-source.rgb24.ref.png
+++ b/test/reference/recording-surface-source.rgb24.ref.png
Binary files differ
diff --git a/test/reference/reflected-stroke.ref.png b/test/reference/reflected-stroke.ref.png
index 1318806..c05eb96 100644
--- a/test/reference/reflected-stroke.ref.png
+++ b/test/reference/reflected-stroke.ref.png
Binary files differ
diff --git a/test/reference/rel-path.rgb24.ref.png b/test/reference/rel-path.rgb24.ref.png
index 78d8a08..0301ed2 100644
--- a/test/reference/rel-path.rgb24.ref.png
+++ b/test/reference/rel-path.rgb24.ref.png
Binary files differ
diff --git a/test/reference/stroke-clipped.ref.png b/test/reference/stroke-clipped.ref.png
new file mode 100644
index 0000000..2d4c5d1
--- /dev/null
+++ b/test/reference/stroke-clipped.ref.png
Binary files differ
diff --git a/test/reference/xcb-huge-subimage.ref.png b/test/reference/xcb-huge-subimage.ref.png
new file mode 100644
index 0000000..a0b24c8
--- /dev/null
+++ b/test/reference/xcb-huge-subimage.ref.png
Binary files differ
diff --git a/test/stroke-clipped.c b/test/stroke-clipped.c
new file mode 100644
index 0000000..4b80794
--- /dev/null
+++ b/test/stroke-clipped.c
@@ -0,0 +1,54 @@
+/*
+ * Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use, copy,
+ * modify, merge, publish, distribute, sublicense, and/or sell copies
+ * of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+#include "cairo-test.h"
+
+#define SIZE 200
+
+static cairo_test_status_t
+draw (cairo_t *cr, int width, int height)
+{
+ int row;
+
+ cairo_set_source_rgb(cr, 1, 1, 1);
+ cairo_paint(cr);
+
+ cairo_set_source_rgb(cr, 1, 0, 0);
+ for(row = 0; row < SIZE; row++) {
+ cairo_rectangle(cr, 0, row, SIZE, 1);
+ cairo_clip(cr);
+
+ cairo_arc(cr, SIZE/2, SIZE/2, SIZE/2-8, 0, 2*M_PI);
+ cairo_stroke(cr);
+
+ cairo_reset_clip(cr);
+ }
+
+ return CAIRO_TEST_SUCCESS;
+}
+
+CAIRO_TEST (stroke_clipped,
+ "Check that the stroke is accurately drawn through smaller clips",
+ "stroke", /* keywords */
+ NULL, /* requirements */
+ SIZE, SIZE,
+ NULL, draw)
diff --git a/test/xcb-huge-subimage.c b/test/xcb-huge-subimage.c
new file mode 100644
index 0000000..fc8e278
--- /dev/null
+++ b/test/xcb-huge-subimage.c
@@ -0,0 +1,81 @@
+/*
+ * Copyright © 2012 Uli Schlachter
+ *
+ * Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use, copy,
+ * modify, merge, publish, distribute, sublicense, and/or sell copies
+ * of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
+ * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ *
+ * Author: Uli Schlachter <psychon@znc.in>
+ */
+
+#include "cairo-test.h"
+
+#define WIDTH 6000
+#define HEIGHT 6000
+
+static cairo_test_status_t
+draw (cairo_t *cr, int width, int height)
+{
+ cairo_surface_t *surface;
+ cairo_surface_t *image;
+ cairo_surface_t *subimage;
+ cairo_rectangle_int_t extents;
+ cairo_t *cr2;
+
+ extents.x = extents.y = 10;
+ extents.width = WIDTH - 20;
+ extents.height = HEIGHT - 20;
+
+ /* We use a similar surface to have way smaller ref images */
+ surface = cairo_surface_create_similar (cairo_get_target (cr),
+ CAIRO_CONTENT_COLOR_ALPHA,
+ WIDTH, HEIGHT);
+
+ /* First we have to defeat xcb's deferred clear */
+ cr2 = cairo_create (surface);
+ cairo_test_paint_checkered (cr2);
+ cairo_destroy (cr2);
+
+ /* Get us an image surface with a non-natural stride */
+ image = cairo_image_surface_create (CAIRO_FORMAT_ARGB32,
+ WIDTH, HEIGHT);
+ subimage = cairo_surface_map_to_image (image, &extents);
+
+ /* Paint the subimage to the similar surface and trigger the big upload */
+ cr2 = cairo_create (surface);
+ cairo_set_source_surface (cr2, subimage, 0, 0);
+ cairo_paint (cr2);
+ cairo_destroy (cr2);
+
+ /* Finally we make sure that errors aren't lost. */
+ cairo_surface_unmap_image (image, subimage);
+ cairo_set_source_surface (cr, surface, 0, 0);
+ cairo_paint (cr);
+ cairo_surface_destroy (image);
+ cairo_surface_destroy (surface);
+
+ return CAIRO_TEST_SUCCESS;
+}
+
+CAIRO_TEST (xcb_huge_subimage,
+ "Test if the maximum request size is honored",
+ "xcb", /* keywords */
+ NULL, /* requirements */
+ 2, 2,
+ NULL, draw)