--- cairo-svg-surface.0.c 2010-12-25 18:21:34 +0400 +++ cairo-svg-surface.c 2013-11-20 14:32:18 +0400 @@ -2404,7 +2404,13 @@ "%s", mask_id, discard_filter ? "" : " \n"); - status = _cairo_svg_surface_emit_paint (mask_stream, surface, CAIRO_OPERATOR_OVER, mask, source, NULL); + // [DS] PCC-3434 apply source transform to mask only if source is an image / not a rect. + // Using same condition here as in _cairo_svg_surface_emit_paint + if (source->type == CAIRO_PATTERN_TYPE_SURFACE && + source->extend == CAIRO_EXTEND_NONE) + status = _cairo_svg_surface_emit_paint (mask_stream, surface, CAIRO_OPERATOR_OVER, mask, source, NULL); + else + status = _cairo_svg_surface_emit_paint (mask_stream, surface, CAIRO_OPERATOR_OVER, mask, 0, NULL); if (unlikely (status)) { cairo_status_t ignore = _cairo_output_stream_destroy (mask_stream); return status;