summaryrefslogtreecommitdiff
path: root/src/cairo-gstate-private.h
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2005-06-14 19:45:22 +0000
committerKristian Høgsberg <krh@redhat.com>2005-06-14 19:45:22 +0000
commit476fe9a66e2be74e65fe2f4e42bda5f4c8b244a0 (patch)
tree4d83e890d040cc75d7205089f99f49df0a1a798c /src/cairo-gstate-private.h
parent663e39a63c6ae223dc3095d29fd95bc8885c74f2 (diff)
Implement path clipping and refactor _cairo_gstate_clip() out in three different functions corresponding to the three different clipping modes.
Add NULL pointers for intersect_clip_path. New test case to exercise PDF clipping code.
Diffstat (limited to 'src/cairo-gstate-private.h')
-rw-r--r--src/cairo-gstate-private.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/cairo-gstate-private.h b/src/cairo-gstate-private.h
index 8a744856..7e2c8597 100644
--- a/src/cairo-gstate-private.h
+++ b/src/cairo-gstate-private.h
@@ -36,7 +36,19 @@
#ifndef CAIRO_GSTATE_PRIVATE_H
#define CAIRO_GSTATE_PRIVATE_H
+#include "cairo-path-fixed-private.h"
+
+struct _cairo_clip_path {
+ unsigned int ref_count;
+ cairo_path_fixed_t path;
+ cairo_fill_rule_t fill_rule;
+ double tolerance;
+ cairo_clip_path_t *prev;
+};
+
typedef struct _cairo_clip {
+ cairo_clip_mode_t mode;
+
/*
* Mask-based clipping for cases where the backend
* clipping isn't sufficiently able.
@@ -59,8 +71,10 @@ typedef struct _cairo_clip {
*/
pixman_region16_t *region;
/*
- * XXX add clip paths here
+ * If the surface supports path clipping, we store the list of
+ * clipping paths that has been set here as a linked list.
*/
+ cairo_clip_path_t *path;
} cairo_clip_t;
struct _cairo_gstate {