mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-01-07 17:10:28 +01:00
image: Use the recording surface content for the recording source
The previous commit should have been a enormous warning that something was horribly wrong. I was determined to preserve the optimisation of replaying onto the matching format, however, we need to provide an alpha channel if required. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
ab924b11a8
commit
242fbb010e
1 changed files with 7 additions and 2 deletions
|
|
@ -642,8 +642,13 @@ _pixman_image_for_recording (cairo_image_surface_t *dst,
|
|||
if (extend == CAIRO_EXTEND_NONE)
|
||||
limit = *extents;
|
||||
|
||||
clone = cairo_image_surface_create (is_mask ? CAIRO_FORMAT_A8 : dst->format,
|
||||
limit.width, limit.height);
|
||||
if (dst->base.content == source->content)
|
||||
clone = cairo_image_surface_create (dst->format,
|
||||
limit.width, limit.height);
|
||||
else
|
||||
clone = _cairo_image_surface_create_with_content (source->content,
|
||||
limit.width,
|
||||
limit.height);
|
||||
cairo_surface_set_device_offset (clone, limit.x, limit.y);
|
||||
|
||||
m = NULL;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue