Commit graph

3907 commits

Author SHA1 Message Date
Vladimir Vukicevic
aaf94ef6c4 [fixpt] remove dependency on some pixman types
Introduce cairo_gradient_stop_t, and remove pixman dependency
for core pattern types.  Perform conversion from cairo types
to pixman types as necessary in fallback code.
2007-07-18 22:45:21 +02:00
Vladimir Vukicevic
e5fdacae1c [fixpt] fix up image surface to translate to 16.16 for pixman 2007-07-18 22:45:21 +02:00
Vladimir Vukicevic
be3516335c [fixpt] Replace cairo_rectangle_int16_t with cairo_rectangle_int_t
Mostly s/cairo_rectangle_int16_t/cairo_rectangle_int_t/,
as well as definitions to pick cairo_rectangle_int_t.
2007-07-18 22:45:21 +02:00
Vladimir Vukicevic
9c38aa3b96 [fixpt] Use _cairo_fixed_mul insted of manual multiplication 2007-07-18 22:45:21 +02:00
Vladimir Vukicevic
0048a26a44 [fixpt] Make fixed point methods static inline and generic
Move the fixed point methods to static inline versions in
cairo-fixed-private.h, and don't hardcode fixed to be 16.16.
2007-07-18 22:45:21 +02:00
Vladimir Vukicevic
76c32f899a [fixpt] Update quartz surface for new types 2007-07-18 13:08:39 -07:00
Søren Sandmann
290daee4ce Add note about pixman dependency in README 2007-07-10 10:31:23 -04:00
Jinghua Luo
1fac791537 [Glitz] fix compilation.
Separating pixman broke the compilation if glitz backend is enabled,
fix it and all compiler warning as well.
2007-07-10 15:09:04 +08:00
Chris Wilson
5819be398c [check-plt] Ignore entries for pixman.
pixman is now an external library, so we now expect PLT entries.
2007-07-05 19:15:10 +01:00
Chris Wilson
35ef8419a9 [cairo-matrix] Check determinant for invalid numbers.
By checking matrices for invalid determinants, we can prevent the
setting and application of invalid matrices.

The trick used here is that NaNs, as specified by IEE754, always
return FALSE in comparisons. Since we know that the square of the
determinant must be positive definite, then if the comparison is
FALSE the computation must have resulted in a NaN.
2007-07-05 19:15:07 +01:00
Chris Wilson
7eaba5d5fb [configure] Only run PostScript tests if we have ghostscript.
During configure check for the ghostscript command line tool (gs) before
enabling the PostScript surface tests for make check.
2007-07-05 19:02:11 +01:00
Søren Sandmann Pedersen
ef967be630 Merge branch 'master' of git+ssh://sandmann@git.freedesktop.org/git/cairo
Conflicts:

	pixman/src/fbcompose.c
	pixman/src/icimage.c
	pixman/src/pixmanint.h
	pixman/src/pixregionint.h
	src/cairo-clip.c
2007-07-02 08:33:29 -07:00
Vladimir Vukicevic
5c7d2d14d7 [fix] Avoid int overflow when allocating large buffers
This patch introduces three macros: _cairo_malloc_ab,
_cairo_malloc_abc, _cairo_malloc_ab_plus_c and replaces various calls
to malloc(a*b), malloc(a*b*c), and malloc(a*b+c) with them.  The macros
return NULL if int overflow would occur during the allocation.  See
CODING_STYLE for more information.
2007-06-29 09:46:08 -07:00
Carl Worth
fc34073464 Increment version to 1.5.1 after the 1.4.10 release 2007-06-27 14:38:41 -07:00
Carl Worth
107a74885a Increment cairo version to 1.4.10 (and libtool versioning to 13:5:11) 2007-06-27 14:05:56 -07:00
Carl Worth
f595ad2348 Add notes to NEWS for 1.4.10 2007-06-27 14:04:27 -07:00
Carl Worth
2bf3e31da9 Prefer local dpy variable instead of display->display
This was a tiny piece of cleanup that had been erroneously included
with some earlier functional changes, (so it went through a cycle
of being applied and reverted). It's back now in its own commit.
2007-06-27 11:11:36 -07:00
Carl Worth
eebb0df512 Revert "[cairo-xlib-display] Hide XErrors during processing of the work queue."
This reverts commit 285b702ef6.

The recent commit of 0791f342b9 fixes
the same bug that 285b702e was fixing, but without introducing any
performance-killing calls to XSync. So we can drop those now.
2007-06-27 11:08:53 -07:00
Carl Worth
b019cb8a7a Revert "[cairo-xlib-surface] Check for errors before installing a NOOP error handler."
This reverts commit 7016614dd9.

We want to avoid any negative performance impacts due to extra calls
to XSync. The fact that X errors can be missed with this appraoch is
undesirable of course---a proper fix will likely involve moving to
XCB which will hopefully allow us to do the error-checking the way
we want without any performance penalty.
2007-06-27 11:07:07 -07:00
Carl Worth
6d021eb4b6 Merge branch 'ooo-fix' into cairo 2007-06-27 11:01:00 -07:00
Chris Wilson
0791f342b9 Avoid deferring resource cleanup for application drawables
This eliminates X errors propagated from cairo due to cleaning up
Render Pictures after the application had already destroyed the
Drawable they reference. (It would be nice if the X server wouldn't
complain that some cleanup work is already done, but there you
have it.)

This fix has been verified to fix the bug causing OpenOffice.org to
crash as described here:

	XError on right click menus in OOo.
	https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=243811

And unlike other proposed fixes for this bug, this fix does not
introduce any new calls to XSync, (and thereby avoids performance
concerns from those).
2007-06-27 10:53:29 -07:00
Søren Sandmann
0c42dbb192 pixman_image_set_transform() returns FALSE on failure 2007-06-21 22:21:11 -07:00
Søren Sandmann
e0cff78b34 Fix bug where _cairo_image_surface_composite_trapezoids() computed the wrong stride for aliased masks 2007-06-21 22:21:11 -07:00
Søren Sandmann
ca5760a289 Fix initialization of radial patterns 2007-06-21 22:21:11 -07:00
Søren Sandmann
12cc32b674 [pixman] Initial port to standalone pixman library. 2007-06-21 22:21:11 -07:00
Chris Wilson
9109946a1a [cairo-directfb] Correct minor typo.
Correct the reference to _cairo_directfb_surface_is_similar.
2007-06-21 15:40:23 +01:00
Nis Martensen
1e76aa66b2 Update INSTALL about status of backends 2007-06-19 11:48:43 -07:00
Carl Worth
02f753c23a Fix cairo-perf-diff to compile cairo-perf explicitly 2007-06-18 18:24:09 -07:00
Vladimir Vukicevic
2477e57de5 [perf] Add pixman_region_init_rects and use in extract_region
Avoid O(N*N) loop in traps_extract_region by letting us hand pixman
an array of rects all at once.
2007-06-18 14:02:41 -07:00
Chris Wilson
285b702ef6 [cairo-xlib-display] Hide XErrors during processing of the work queue.
It is possible for the resources that we defer freeing to be already
destroyed and trigger an XError whilst processing the work queue. For
example, the application renders to a Window and then destroys the
Drawable before proceeding with more rendering. This will trigger an
invalid Picture from RenderFreePicture whilst attempting to free the
resources.

By ignoring the possibility that the application could allocate a fresh
resource with the same ID, we can simply hide the XErrors...

Fixes: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=243811
2007-06-15 21:16:49 +01:00
Chris Wilson
7016614dd9 [cairo-xlib-surface] Check for errors before installing a NOOP error handler.
Call XSync before ignoring errors from XGetImage to avoid hiding
unassociated errors. Similarly, call XSync before reinstalling the old
error handler to ensure no errors creep out of the ignored section.
2007-06-15 21:00:50 +01:00
Ryan Lortie
0c5d28a4e5 [xlib] Create source xrender Picture with IncludeInferiors
When an xlib surface is used as the source of a draw operation this
will cause the contents of child windows to be included in the source
data.  The semantics of drawing to xlib surfaces are unchanged (ie:
draws are still clipped by child windows overlapping the destination
window).
2007-06-13 18:59:22 -04:00
Brian Ewins
817d4b0c9a [atsui] Document ATSUI
Add cairo_atsui_font_face_create_for_atsu_font_id
and ATSUI to the documentation. Don't enable it yet,
since this is still unsupported.
2007-06-13 01:27:37 +01:00
Brian Ewins
fd1edaa5d3 [quartz] remove unused code
clean up warnings about unused code: removing 
_cairo_quartz_cairo_path_to_quartz_path and the functions
it calls.
2007-06-13 01:27:36 +01:00
Brian Ewins
d7a0816ec3 [quartz] move glyph array declarations
Move declarations causing a warning. A separate patch from
the other warning cleanups because it moves where the allocation
happens.
2007-06-13 01:27:36 +01:00
Brian Ewins
bf39b28b77 commit 75be87b4093aaa7f477d587d5a68308cade1b29c
[quartz] move glyph array declarations

    Move declarations causing a warning. A separate patch from
    the other warning cleanups because it moves where the allocation
    happens.
2007-06-13 01:27:36 +01:00
Brian Ewins
2034d1dbd5 [quartz] pass quartz_stroke_t not CGContextRef
Fix a typo where an incompatible pointer was being passed.
2007-06-13 01:27:36 +01:00
Behdad Esfahbod
54bbe44b08 [TODO] Add link to Adrian's finer-grain fallback thread 2007-06-11 17:51:37 -04:00
Vladimir Vukicevic
ef3c64fd13 [misc] Blow away last remaining $Id$ directives in sources 2007-06-11 09:27:11 -07:00
Behdad Esfahbod
853f23e18c [test] Use check_PROGRAMS instead of custom made SUPPORT_PROGS
It better handles $(EXEEXT) and is exactly made for this purpose.
2007-06-11 02:42:04 -04:00
Behdad Esfahbod
1d86c7fa88 [perf] Link to librt if available
This is needed on Solaris, but also works on Linux.
2007-06-09 13:48:32 -04:00
Carl Worth
85d045f267 Update version to 1.4.9 after the 1.4.8 release. 2007-06-08 16:08:44 -07:00
Carl Worth
fea4f344c4 Update version to 1.4.8 (and libtool info to 13:4:11) 2007-06-08 15:49:12 -07:00
Carl Worth
0b19ff1d3f Add include of X11/Xlib.h to cairo-xlib-xrender.h
This makes this header file self-sufficient. Thanks to
Sam Sirlin <samuel.w.sirlin@jpl.nasa.gov> for pointing
this out.
2007-06-08 15:36:05 -07:00
Brian Ewins
8223c976d5 [NEWS] add note about quartz fixes
We've got 11 less failures in the quartz tests this time around,
worth a mention.
2007-06-08 01:56:10 +01:00
Vladimir Vukicevic
00063a65f7 [quartz] fix DO_IMAGE
The implementation of DO_IMAGE leaks memory via a referenced surface,
and wasn't applied for strokes and glyphs. This patch corrects those
issues.
2007-06-08 01:46:27 +01:00
Brian Ewins
39e6a0090f [quartz] fall back on extended gradients
A temporary fix for mozilla bug 379321, use an image fallback for
gradients that use EXTEND_REPEAT or EXTEND_REFLECT.
2007-06-08 01:46:27 +01:00
Brian Ewins
7c1afdcd59 [quartz] fixes the offsets in the font-matrix test
Apply the font matrix offset to text on the quartz surface, if necessary.
2007-06-08 01:46:26 +01:00
Brian Ewins
55f1dbd0fb [quartz] ensure that line widths are scaled.
cairo-gstate applies the ctm to the coordinates used in paths,
but not to the line width. In quartz this ends up drawing unscaled
lines. This is a minimal fix - it undoes the scaling applied to the
points and then draws the path scaled correctly.
2007-06-08 01:46:25 +01:00
Brian Ewins
5a9de1b5c9 [atsui] remove unused code
Remove CGAffineTransformMakeWithCairoFontScale.
2007-06-08 01:46:25 +01:00