Commit graph

8765 commits

Author SHA1 Message Date
Benjamin Otte
9669faa936 gl: Handle errors from _cairo_gl_gradient_render()
Thanks Andrea for finding this.
2010-08-08 17:23:05 +02:00
Benjamin Otte
e31b56e020 configure: Fix gobject handling
1) Explicitly depend on glib, too.
2) Don't link gobject into libcairo proper (thanks Joonas for noticing).
2010-08-08 16:09:13 +02:00
Andrea Canciani
ae2b7b13cd pattern: Simplify degenerate linear pattern to solid colors
Degenerate linear patterns are considered clear if they have
EXTEND_NONE, the average of the first and the last stop if they are
EXTEND_PAD, the weighted average of the stops (based on the size of
the interpolation range in which they are active, just like integrating
over the whole interpolation range and taking the average) if they are
EXTEND_REPEAT or EXTEND_REFLECT.

Fixes degenerate-linear-gradient
2010-08-08 12:07:08 +02:00
Andrea Canciani
d54a5a9fc9 pattern: Add gradient degeneracy testing functions
Introduce two new (private) functions for testing the degeneracy of linear
and radial gradients and use them instead of verbose (and error-prone) tests.
2010-08-08 10:53:51 +02:00
Andrea Canciani
63434bc438 gstate: Correct comment 2010-08-08 10:53:51 +02:00
Andrea Canciani
28cd511fb9 Correct color stops comparison function
Two clear stops with different "underlying" colors must be considered
different, since when interpolated with non-clear colors they will
produce different results.
2010-08-08 10:53:44 +02:00
Andrea Canciani
f71a618bd2 Fix configuration if gobject is absent
Autodetect gobject and only use it if present.
Its absence is not to be considered a failure since it's not required.
2010-08-07 21:32:09 +02:00
Benjamin Otte
661f4859cd Add cairo-gobject library
This library is supposed to contain GType declarations for Cairo types.
It is also meant to support gobject-introspection binding creation.
2010-08-07 20:19:27 +02:00
Søren Sandmann Pedersen
fc4e8f0363 Update documentation to reflect that rgb565 is no longer deprecated. 2010-08-07 12:10:49 -04:00
Andrea Canciani
de606af5d6 quartz: improve backend detection
Quartz previously crashed with NULL backends and didn't check for
the backend type when getting a CGContext from a quartz surface,
returning meaningless data for subsurfaces.
2010-08-07 12:37:22 +02:00
Andrea Canciani
056ce165c4 quartz: fix solid masking fallback
Falling back when painting would ignore the alpha value (which is
needed to have the correct mask opacity).
_cairo_quartz_surface_paint_cg doesn't fallback, so the usual mask
fallback path is now taken, as expected.
2010-08-07 12:21:06 +02:00
Andrea Canciani
bdeade14ea quartz: fix stroking with unbounded operators
Self-intersecting strokes were drawn incorrectly when an unbounded
operator was used, since the fixup operation also cleared the
intersection.

Fixes clip-stroke-unbounded.
2010-08-06 20:24:52 +02:00
Andrea Canciani
8f38d2aa29 test: improve clip-*-unbounded tests
Merge clip-*-unbounded tests and add self-intersections to the paths
that are drawn. This exposes a bug in the unbounded fixup code in quartz.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-08-06 19:36:37 +02:00
Benjamin Otte
142df6f963 configure: Disable xml backend by default
We don't want to enable it by default when nobody uses it.
2010-07-30 22:27:28 +02:00
Benjamin Otte
9f33f8453b configure: Disable tee backend by default
We don't want to enable it by default when nobody uses it.
2010-07-30 22:27:27 +02:00
Benjamin Otte
9f4d677e2a tee: Move definitions into separate header 2010-07-30 22:27:08 +02:00
Kristian Høgsberg
14639e6b85 egl: Use EGL_KHR_surfaceless_opengl extension when available
This lets us avoid creating a throwaway pbuffer just to make the
context current.
2010-07-28 23:17:42 -04:00
Chris Wilson
b6fd673d37 version: 1.9.15 post-snapshot bump 2010-07-26 13:15:38 +01:00
Chris Wilson
ed8c6f4254 version: 1.9.14 snapshot 2010-07-26 12:53:44 +01:00
Chris Wilson
81094cf462 NEWS: 1.9.14 2010-07-26 12:52:56 +01:00
Andrea Canciani
c1fcbd0322 quartz: fix REFLECT radial gradients
The interpolation range of repeating radial gradients can safely be
reflected around any integer (previously 0), but for reflect-extended
radial gradients can only be reflected around odd integers if the
appearance is to be the same, thus reflecting around 1 is correct for both.

Fixes radial-gradient.
2010-07-26 11:39:27 +02:00
Chris Wilson
3898e46d1d image: Compensate mask origins for glyph clipping
Fixes the regression in bitmap-font and large-font pointed out by Andrea
Canciani since ef067933.
2010-07-23 09:44:00 +01:00
M Joonas Pihlaja
53fcfc781e build: Typos in comments.
Fix inline "dnl" strings left over from a string
substitution "--" -> "dnl".
2010-07-21 22:39:40 +03:00
Hib Eris
fd1e731c9d build: Fix pthread detection code when there isn't one.
The code was testing the output variable $use_pthread rather than
the input variable $enable_pthread when checking that pthreads
were actually found when requested.
2010-07-21 22:34:05 +03:00
Karl Tomlinson
108b1c7825 clip: consider gstate target extents in _cairo_gstate_copy_clip_rectangle_list
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=29125

To be consistent with _cairo_gstate_clip_extents, the context's clip
should be intersected with the target surface extents (instead of only
using them when there is no clip).

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-17 11:32:02 +01:00
Karl Tomlinson
b79ea8a6ca clip: consider all_clipped in _cairo_clip_get_extents
If the gstate clip in _cairo_gstate_int_clip_extents() has all_clipped
set (and path NULL), then it returns the gstate target extents instead of
an empty rectangle.  If the target is infinite, then it says the clip is
unbounded.

Fixes https://bugs.freedesktop.org/show_bug.cgi?id=29124
Tested-by test/get-clip

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-17 11:30:51 +01:00
Karl Tomlinson
6a51159013 test: return CAIRO_TEST_FAILURE from get-clip preamble on failure
https://bugs.freedesktop.org/show_bug.cgi?id=29120
2010-07-17 11:30:35 +01:00
Karl Tomlinson
f2fa15680e clip: return empty clip from _cairo_clip_copy_rectangle_list when all_clipped
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=29122
Tested by test/get-clip

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-17 11:29:54 +01:00
Karl Tomlinson
33ac203587 test: use the surface size expected in get-clip phase "No clip set"
https://bugs.freedesktop.org/show_bug.cgi?id=29121
2010-07-17 11:22:28 +01:00
Chris Wilson
bac5c28a18 boilerplate: Offset the xlib window
An idea courtesy of Benjamin Otte is to stress the drivers a bit more by
not rendering to 0,0. Under various circumstances rendering to a Window
is mapped onto the Screen root Window with a collection of offsets and
clips by X. It is easy for the driver to make a mistake and misrender...
2010-07-17 10:09:14 +01:00
Benjamin Otte
51b0c21f02 build: Add explicit dependcy to cxx lib
Otherwise the build will fail because it doesn't add the dependency
manually.

https://bugs.freedesktop.org/show_bug.cgi?id=29114
2010-07-16 19:49:53 +02:00
Oleg Romashin
6b92d5a0f9 qt: Use native glyph rendering.
Remove the hack of using the xlib surface to do glyph rendering and use
the new interface introduced with Qt4.7, or else fallback to image
rendering with freetype.

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
[2 files changed, 35 insertions(+), 140 deletions(-) \o/]
2010-07-16 09:49:42 +01:00
Chris Wilson
f53f072a22 clip: Do the NULL check before the dereference.
Breakage introduced in the commit earlier today.
2010-07-12 18:53:29 +01:00
Chris Wilson
ef0679333d image: Manually clip against bounds when rendering directly
This is path is slightly peculiar in that it explicitly avoid the
intermediate mask and the geometry is not pre-clipped.

This in conjunction with the previous commit fixes:

  Clip doesn't work for text
  https://bugs.freedesktop.org/show_bug.cgi?id=29008

which is captured in test/partial-clip-text.
2010-07-12 16:33:42 +01:00
Chris Wilson
679e5a600b Differentiate between reducing clip to composite extents and a rectangle
This is required for handling glyphs when rendering directly to the
surface.
2010-07-12 16:33:38 +01:00
Chris Wilson
8546a87788 test: Add partial-clip-text
This exercises a bug found by Igor Nikitin:

  https://bugs.freedesktop.org/show_bug.cgi?id=29008
2010-07-12 16:33:38 +01:00
Chris Wilson
53ee897449 version: Post-snapshot bump to 1.9.13 2010-07-12 12:37:31 +01:00
Chris Wilson
aa4cd8287f version: 1.9.12 snapshot 2010-07-12 12:19:54 +01:00
Chris Wilson
53b129dd8a NEWS for 1.9.12. 2010-07-12 12:19:54 +01:00
Chris Wilson
01380f3a56 test: Missing REFERENCE_IMAGES 2010-07-12 11:50:42 +01:00
Chris Wilson
459b8ae660 Make distcheck happy. 2010-07-12 11:05:57 +01:00
Andrea Canciani
d56b171802 test: Add halo quartz reference images
When quartz-font is enabled, halo and halo-transform fonts have a
different shape.
2010-07-12 10:36:24 +02:00
M Joonas Pihlaja
9107895789 test: Add comments explaining the bug in bug-seams.
Where two rasterization methods meet, havoc occurs.
2010-07-12 11:03:15 +03:00
M Joonas Pihlaja
0152db263b build: Sync up autogenerated win32 build files. 2010-07-12 10:39:18 +03:00
Eric Anholt
06ffb7df71 gl: Only use a mat3 for the transformation for gradients coordinates.
No point in passing in a column of zeroes that we multiply by zero, or
the row that we drop on the floor.  We could do even better by just
passing in a 3x2, at the expense of adding a language version
dependency (or just pass in 2 vectors).

No significant performance difference.
2010-07-11 21:56:55 -07:00
M Joonas Pihlaja
1e7485f8e5 trace: Avoid stdbool.h C99ism.
There is no <stdbool.h> on old Solaris without invoking
c99 mode explicitly.
2010-07-12 00:50:13 +03:00
M Joonas Pihlaja
97529a3713 build: Avoid shifting shell parameters that aren't there.
The shift primitive of the Solaris 9 Bourne shell doesn't like
it if we try to shift more formal arguments than are there.
This causes the compare_versions function in autogen.sh to croak when
the actual and compared versions differ in the number of
components.
2010-07-12 00:49:57 +03:00
Benjamin Otte
dd6026b613 doc: Make the necessity of flush/mark_dirty more obvious 2010-07-11 23:32:12 +02:00
Benjamin Otte
8a1944f45b check: Allow unprefix type names in the title
Some documentation sections use the type name as the title, and we don't
want to use that title as a link.
2010-07-11 23:32:12 +02:00
M Joonas Pihlaja
f0466ecf7d build: Fix typo in pthread test program.
Missing a semicolon after pthread_cleanup_push.  Incredibly
only openbsd 4.5 minded.
2010-07-11 21:57:40 +03:00