[cairo-commit] src/cairo-surface-clipper.c
Chris Wilson
ickle at kemper.freedesktop.org
Fri Aug 5 10:24:00 PDT 2011
src/cairo-surface-clipper.c | 3 +++
1 file changed, 3 insertions(+)
New commits:
commit 9ef003c5fce30956fefb2f4d9a1ded85cb296b4f
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date: Fri Aug 5 18:21:26 2011 +0100
clipper: Don't emit an empty clip-path for no clip boxes
If there are no clip boxes, we do not need to emit an empty clip which
only confuses the users of the surface-clipper.
Spotted by Andrea Canciani and cairo-quartz
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/cairo-surface-clipper.c b/src/cairo-surface-clipper.c
index bbc286b..8429db7 100644
--- a/src/cairo-surface-clipper.c
+++ b/src/cairo-surface-clipper.c
@@ -74,6 +74,9 @@ _cairo_surface_clipper_intersect_clip_boxes (cairo_surface_clipper_t *clipper,
cairo_status_t status;
int i;
+ if (clip->num_boxes == 0)
+ return CAIRO_STATUS_SUCCESS;
+
/* Reconstruct the path for the clip boxes.
* XXX maybe a new clipper callback?
*/
More information about the cairo-commit
mailing list