diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2011-08-14 14:45:00 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2011-08-14 14:45:00 +0100 |
commit | 0053a44f6b9806eb61452859ba1eb2ca8c72f564 (patch) | |
tree | 9bc580816960f6a3adfe712955cae9517a0750e2 /src/cairo-recording-surface-private.h | |
parent | eb09a686388b889f67f3a9b2c820575a1cfbc304 (diff) | |
download | cairo-0053a44f6b9806eb61452859ba1eb2ca8c72f564.tar.gz |
record: Offset the clip by the replay transformation as well
Fixes push-group-offset which reduces to a replay of a recording surface
inside a recording surface and forgot to offset the clip imposed by the
extents of the first recording surface into device space.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/cairo-recording-surface-private.h')
-rw-r--r-- | src/cairo-recording-surface-private.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/cairo-recording-surface-private.h b/src/cairo-recording-surface-private.h index b7d0ebf2a..5a897da17 100644 --- a/src/cairo-recording-surface-private.h +++ b/src/cairo-recording-surface-private.h @@ -184,7 +184,18 @@ _cairo_recording_surface_get_bounds (cairo_surface_t *surface, return TRUE; } -cairo_private cairo_bool_t -_cairo_surface_is_recording (const cairo_surface_t *surface); +/** + * _cairo_surface_is_recording: + * @surface: a #cairo_surface_t + * + * Checks if a surface is a #cairo_recording_surface_t + * + * Return value: %TRUE if the surface is a recording surface + **/ +static inline cairo_bool_t +_cairo_surface_is_recording (const cairo_surface_t *surface) +{ + return surface->backend->type == CAIRO_SURFACE_TYPE_RECORDING; +} #endif /* CAIRO_RECORDING_SURFACE_H */ |