diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2009-08-29 12:08:12 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2009-08-29 17:10:05 +0100 |
commit | 21225a7163bc93d34d3e395c840faaba24046bb6 (patch) | |
tree | 0c95841ea3b47b20b0da4ecc307f42a6ce351653 /src/cairo-surface-fallback.c | |
parent | ac6c6fe1d39effd5b6b382f0f1199af824868ef4 (diff) | |
download | cairo-21225a7163bc93d34d3e395c840faaba24046bb6.tar.gz |
[clip] Pass in destination offset for combining with clip-mask
When combining a clip-mask with a subsurface, as when used to combine with
the composite mask, we need to pass the destination surface offset to the
clip so that the paths can be corrected for the new surface.
Diffstat (limited to 'src/cairo-surface-fallback.c')
-rw-r--r-- | src/cairo-surface-fallback.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/cairo-surface-fallback.c b/src/cairo-surface-fallback.c index 8fa7fa98d..0f5f8212e 100644 --- a/src/cairo-surface-fallback.c +++ b/src/cairo-surface-fallback.c @@ -163,8 +163,12 @@ _create_composite_mask_pattern (cairo_surface_pattern_t *mask_pattern, if (unlikely (status)) goto CLEANUP_SURFACE; - if (clip_surface) - status = _cairo_clip_combine_with_surface (clip, mask); + if (clip_surface) { + status = _cairo_clip_combine_with_surface (clip, + mask, + extents->x, + extents->y); + } _cairo_pattern_init_for_surface (mask_pattern, mask); @@ -838,9 +842,9 @@ _composite_spans_draw_func (void *closure, cairo_composite_rectangles_t rects; cairo_composite_spans_info_t *info = closure; - _cairo_composite_rectangles_init ( - &rects, extents->x, extents->y, - extents->width, extents->height); + _cairo_composite_rectangles_init (&rects, + extents->x, extents->y, + extents->width, extents->height); /* The incoming dst_x/y are where we're pretending the origin of * the dst surface is -- *not* the offset of a rectangle where |