diff options
author | Adrian Johnson <ajohnson@redneon.com> | 2013-09-13 22:14:49 +0930 |
---|---|---|
committer | Adrian Johnson <ajohnson@redneon.com> | 2013-09-13 22:14:49 +0930 |
commit | 2d6705671a900251f00c6b59375bd4d23ec6b4d0 (patch) | |
tree | 26885c38ef39d57cf637ddcb0a05ab4e8d9cfdc5 | |
parent | 266d6e71566ac8c5e360c0b32fb78e23e6a06168 (diff) |
ps: fix embedding of mime data
-rw-r--r-- | src/cairo-ps-surface.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/cairo-ps-surface.c b/src/cairo-ps-surface.c index 5e6206a..dfab4f7 100644 --- a/src/cairo-ps-surface.c +++ b/src/cairo-ps-surface.c @@ -3093,6 +3093,16 @@ _cairo_ps_surface_emit_surface (cairo_ps_surface_t *surface, { cairo_int_status_t status; + if (source_pattern->type == CAIRO_PATTERN_TYPE_SURFACE && + source_pattern->extend != CAIRO_EXTEND_PAD) + { + cairo_surface_t *surf = ((cairo_surface_pattern_t *) source_pattern)->surface; + + status = _cairo_ps_surface_emit_jpeg_image (surface, surf, width, height); + if (status != CAIRO_INT_STATUS_UNSUPPORTED) + return status; + } + if (source_surface->type == CAIRO_SURFACE_TYPE_RECORDING) { if (source_surface->backend->type == CAIRO_SURFACE_TYPE_SUBSURFACE) { cairo_surface_subsurface_t *sub = (cairo_surface_subsurface_t *) source_surface; @@ -3102,12 +3112,6 @@ _cairo_ps_surface_emit_surface (cairo_ps_surface_t *surface, } } else { cairo_image_surface_t *image = (cairo_image_surface_t *) source_surface; - if (source_pattern->extend != CAIRO_EXTEND_PAD) { - status = _cairo_ps_surface_emit_jpeg_image (surface, source_surface, - width, height); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) - return status; - } status = _cairo_ps_surface_emit_image (surface, image, op, source_pattern->filter, stencil_mask); |