[cairo-commit] src/cairo-ps-surface.c

Adrian Johnson ajohnson at kemper.freedesktop.org
Tue Mar 18 03:39:27 PDT 2008


 src/cairo-ps-surface.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit b83b8c26f5d64fa07b56a747dec681c6626a0297
Author: Adrian Johnson <ajohnson at redneon.com>
Date:   Mon Mar 17 23:38:34 2008 +1030

    Optimize generated PostScript when EXTEND_PAD is used
    
    Allow image patterns with EXTEND_PAD to use the currentfile
    optimization.

diff --git a/src/cairo-ps-surface.c b/src/cairo-ps-surface.c
index f5838ab..8614b8a 100644
--- a/src/cairo-ps-surface.c
+++ b/src/cairo-ps-surface.c
@@ -2885,7 +2885,8 @@ _cairo_ps_surface_paint (void			*abstract_surface,
     _cairo_rectangle_intersect (&extents, &surface_extents);
 
     if (source->type == CAIRO_PATTERN_TYPE_SURFACE &&
-	source->extend == CAIRO_EXTEND_NONE)
+	(source->extend == CAIRO_EXTEND_NONE ||
+	 source->extend == CAIRO_EXTEND_PAD))
     {
 	_cairo_output_stream_printf (stream, "q %d %d %d %d rectclip\n",
 				     extents.x,
@@ -2976,7 +2977,8 @@ _cairo_ps_surface_fill (void		*abstract_surface,
 #endif
 
     if (source->type == CAIRO_PATTERN_TYPE_SURFACE &&
-	source->extend == CAIRO_EXTEND_NONE)
+	(source->extend == CAIRO_EXTEND_NONE ||
+	 source->extend == CAIRO_EXTEND_PAD))
     {
 	_cairo_output_stream_printf (surface->stream, "q\n");
 


More information about the cairo-commit mailing list