Commit graph

721 commits

Author SHA1 Message Date
Carl Worth
e840c120dd Fix 'make distcheck' by mentioning test/pdiff in DIST_SUBDIRS 2006-12-06 13:19:30 -08:00
M Joonas Pihlaja
48b42efcfe test: check for tessellator regression from missed stop events
The new tessellator contains a regression where stop events
that aren't followed by start events sometimes cause the
trapezoid to the left of an edge to be too high.
2006-12-06 05:58:44 +02:00
M Joonas Pihlaja
e94e0a1ca2 test: check if cairo_in_fill() is reporting false positives for empty trapezoids.
cairo_in_fill() may report true if a query point lands on an edge of an
empty trapezoid.
2006-12-06 05:58:44 +02:00
M Joonas Pihlaja
00d7b6acdd test: tessellator event comparator test case for degenerate edges.
There's currently a regression bug in the tessellation code from
switching to the new tessellator.  The bug is caused by
confusion in the comparator used to order events when there are
degenerate edges.  This test is derived from the zrusin-another
performance test case.
2006-12-06 05:58:44 +02:00
Dan Amelang
d5fcbfc29f Purge cairo-test of all calls to round()
Although round() is in the C99 standard, it isn't available in all
toolchains on which cairo is compiled (VC++, for example).
2006-12-01 12:46:55 -08:00
Carl Worth
170d35b034 pdiff: Add missing newlins at end of files. 2006-11-29 23:01:30 -08:00
Carl Worth
c863315285 Hook up Makefiles for perceptualdiff. 2006-11-29 22:55:37 -08:00
Carl Worth
6e06b68452 Remove all libtiff-related code by #ifdef 2006-11-29 22:55:31 -08:00
Carl Worth
2b92556abe Use uint32_t instead of the non-standard uint32 2006-11-29 22:55:00 -08:00
Carl Worth
812fd53499 Add perceptualdiff program totest/pdiff.
The perceptualdiff program was written by Hector Yee with contributions
from Scott Corley and Mick Weiss. It is hosted at http://pdiff.sourceforge.net
The source code added here was obtained by:

	svn co https://svn.sourceforge.net/svnroot/pdiff/trunk pdiff

which gave revision 22 of the source code.

The perceptualdiff program is available under the terms of the GNU GPL,
so I've added a note to COPYING about this program, (and the fact that
it is auxiliary only, and does not affect the license of the implementation
of cairo itself).
2006-11-29 22:40:28 -08:00
Behdad Esfahbod
72a4a98346 [test|perf|boilerplate/Makefile.am] Add -I$(top_builddir)/src to INCLUDES
needed to find cairo-features.h when building out of tree.
2006-11-27 13:23:13 -05:00
Carl Worth
02804773e7 give the big-trap test the XFAIL treatment.
We'll need to rewrite this test (and the way cairo is compiled for
testing) before it can exercise the bug of interest. In the
meantime, let's just give it an "expected failure" status.
2006-11-22 16:52:18 -08:00
Carl Worth
fdbb820ece test: Use round to pass only integers to cairo_show_glyphs (in 3 more tests)
This is the same fix as in the recent commit (166dffc96a)
but for the same idiom that appears in the operator-clear,
operator-source, and unbounded-operator tests. This fixes
the failures that were introduced by the recent switch to
_cairo_lround.
2006-11-22 16:43:45 -08:00
Carl Worth
166dffc96a test/clip-operator: Use round to pass only integers to cairo_show_glyphs
We were previously passing half-integer values here, which will
not be robust to changes in the rounding mode used for
cairo_show_glyphs. Use round() to match the rounding expected
by the reference images.
2006-11-22 16:25:53 -08:00
Vladimir Vukicevic
9cffc56228 [test] add big-trap test
This test fills a single path (a trapezoid, even) that's larger than the
16.16 precision used in pixman and other code.  It leads to memory
scribbling and a crash.  Note that there is no crash if a clip is not set.
2006-11-20 15:30:04 -08:00
Emmanuel Pacaud
10920c1326 Merge branch 'svgprint' 2006-11-18 12:59:12 +01:00
Carl Worth
eeb1fa42aa Add missing pattern-getters-ref.png to Makefile to avoid breaking distcheck target 2006-11-14 15:13:58 -08:00
Carl Worth
28a9f1dd14 Fix get-clip test for surfaces not implementing set_clip_region 2006-11-14 15:13:58 -08:00
Carl Worth
7b86cf513e Remove non-existent reference images from Makefile to avoid breaking distcheck target 2006-11-14 15:13:58 -08:00
Emmanuel Pacaud
2928f6eb5f test/pixman-rotate.c: Don't issue a show_page, it's already done in cairo-test.c 2006-11-12 20:49:34 +01:00
Emmanuel Pacaud
4f02395267 Use SVG multipage capability. 2006-11-12 20:45:50 +01:00
Vladimir Vukicevic
6db219c3a1 [win32] clean up win32_surface_composite
Make sure that all operations are correct (the operations chosen
are listed in cairo-win32-surface.c); in particular, deal with the extra
byte present in FORMAT_RGB24 surfaces correctly.

Also adds support for calling StretchDIBits to draw RGB24
cairo_image_surfaces directly.
2006-11-07 13:12:09 -08:00
Carl Worth
777eaf326a test/Makefile.am: Fix typo in EXTRA_DIST that was breaking distcheck 2006-11-07 01:33:40 -08:00
Jamey Sharp
b0f5af3b47 Add clip-push-group to .gitignore. 2006-10-29 10:59:30 -08:00
Christian Biesinger
a34ba73136 [beos] Allow a pixel error of 1 for BeOS tests
That allows us to delete the BeOS-specific reference images.
2006-10-27 23:51:56 +02:00
Ian Osgood
acac0c1966 don't squish tiny images in test/index.html 2006-10-26 09:57:32 -07:00
Carl Worth
76f816c765 test/paint-repeat: Use offset larger than source surface for better stress testing 2006-10-25 12:52:02 -07:00
Carl Worth
06d3786b2c Add new paint-repeat test
I added this test originally to make it easier to debug
some recent bugs, (the test suite did have some repeating
in the checkered backgrounds, but with an offset of 0,
and then also in trap clip with an offset larger than the
surface itself). This test exercises repeating more directly.

It also triggers a bug in the PostScript backend that I've
not yet investigated. So the test does fail currently.
2006-10-25 12:52:02 -07:00
Behdad Esfahbod
7421e8af0c [test] Make sure tests are not relinked unnecessarily
What was causing it was making all tests depend on all, to make sure
../boilerplate is built first.  I'm not making all tests depend on
../boilerplate/libcairoboilerplate.la and ../src/libcairo.ls and added rules
to build those (by changing dir and making them).
2006-10-25 15:29:00 -04:00
Carl Worth
670b3ce243 test: Update reference images due to previous change to _cairo_color_compute_shorts
The previous change was in b62710d4f8
We just forgot to update the reference images at the time so there
have been false failure results in the test suite until now.
2006-10-23 12:46:25 -07:00
Carl Worth
f894ebf980 clip-push-group: Adjust test slightly to ensure mask-based clip is not anchored at the origin
This should help us test if there's an offset problem in copying
the mask-based clip during cairo_push_group.
2006-10-19 15:45:53 -07:00
Carl Worth
f880f5e57b test: Add clip-push-group to demonstrate crash in cairo_push_group
The crash happens anytime mask-based clipping is in effect
at the time of cairo_push_group. The crash was first reported
here:
	http://lists.freedesktop.org/archives/cairo/2006-August/007698.html
2006-10-19 15:43:02 -07:00
Carl Worth
40e1c0246d Add neglected reference images for infinite-join test 2006-10-18 15:18:11 -07:00
Carl Worth
e21c155e73 Merge branch '8379' into cairo 2006-10-18 15:03:04 -07:00
Carl Worth
5b7a7f39ad test/infinite-join: Modify to draw something visible, and make the output a more reasonable size.
The modification was performed with care to ensure that the bug
is still exercised. Also, reference images are added.
2006-10-18 15:01:58 -07:00
Jamey Sharp
f7068de7f7 Update .gitignore in boilerplate and test. 2006-10-12 23:47:37 -07:00
Carl Worth
78ad834d81 Fix typo of , instead of || which was causing a test to be ignored
Thanks to a gcc warning for catching this one, (statement with
no effect, or similar).
2006-10-12 14:21:55 -07:00
Vladimir Vukicevic
cd6b44e9c9 [test] Fix composite-integer-translate-over test
This test wasn't translating by an integer, but instead by 5.5.  Fixed
test and reference image.
2006-09-29 14:44:00 -07:00
Carl Worth
e4dc73ab1c Rename test from stale path-data name to copy-path 2006-09-26 15:48:06 -07:00
Carl Worth
5f833c134b Fix cairo_copy_path and cairo_copy_path_flat to propagate errors.
One of these functions was already documented to be doing this, and
the other one should have been. Now the documentation and behavior
for both are consistent, (and the path-data test case verifies this).
2006-09-26 15:48:06 -07:00
Robert O'Callahan
191e108b93 Add clip getters API + tests
Add new public API methods:

void cairo_clip_extents (cairo_t *cr,                                               double *x1, double *y1,
    double *x2, double *y2);
cairo_rectangle_list_t *cairo_copy_clip_rectangles (cairo_t *);
void cairo_rectangle_list_destroy (cairo_rectangle_list_t *);

Also add 'get-clip' and 'get-path-extents' tests.
2006-09-25 23:22:45 -07:00
Carl Worth
8744929030 Add test case from bug #8379 demonstrating infinite loop during round join 2006-09-21 15:13:47 -07:00
Vladimir Vukicevic
303b529195 dash and pattern getter functions
Adds API functions for inspecting the current dash state, as well as
the contents of pattern objects:

  cairo_get_dash
  cairo_get_dash_count
  cairo_pattern_get_rgba
  cairo_pattern_get_surface
  cairo_pattern_get_color_stop_rgba
  cairo_pattern_get_color_stop_count
  cairo_pattern_get_linear_points
  cairo_pattern_get_radial_circles
2006-09-19 12:19:21 -07:00
Vladimir Vukicevic
a56b962428 Add win32 output files to gitignore 2006-09-19 12:19:21 -07:00
Vladimir Vukicevic
924bbd06f3 Check for valid path status value before calling _cairo_set_error
cairo_status_t is a signed type, so we need to check for invalid codes
that are < 0 as well.

Also removes the MSVC goop in path-data.c that was attempting to work
around the assert earlier.
2006-09-11 12:36:41 -07:00
Vladimir Vukicevic
e1a8a8b65a [win32] Set win32 assertion failure handlers for tests to stderr
assert() will default to displaying a dialog box, which makes it hard
to run tests automatically.  Set the reporting mode to only report
to stderr in cairo_test(), and in path-data, since that triggers
an early assert.
2006-09-09 23:54:40 -07:00
Vladimir Vukicevic
00d5a2ed48 [win32] Makefile.win32: use correct (/MD) runtime library flag everywhere
There was a bad mix of LIBCMT (the static runtime lib) and MSVCRT (the dynamic
one) before, because LIBCMT is the default.  This specifies /MD everywhere.
2006-09-09 23:29:17 -07:00
Vladimir Vukicevic
d78fd375d3 [win32] Makefile.win32: fix test and add html targets
Add html target to toplevel and test/ Makefile.win32
2006-09-09 22:18:47 -07:00
Vladimir Vukicevic
d3076a1843 Merge branch 'master' of git+ssh://git.cairographics.org/git/cairo into cairo-master 2006-09-09 18:57:57 -07:00
Vladimir Vukicevic
9735cb9a24 Improve make-html.pl, add self-contained output format
Setting CAIRO_TEST_SHOW_INLINE in the environment before running
make-html.pl will generate a html file with all the logs and necessary
images inlined as data URI's.
2006-09-09 18:55:46 -07:00