diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2009-08-13 17:21:05 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2009-08-29 08:08:36 +0100 |
commit | a9d997fecd54cea7dcd71487a24dbae14d0073a8 (patch) | |
tree | 78939c70f6411d9600630d5080871dc730e152ab /test | |
parent | 28887ac272c8a36a41da4d6d58044164b94da6f3 (diff) |
[script] Introduce cairo_script_context_t
cairo_script_context_t is an encapsulation object for interfacing with the
output - multiple surfaces can share the same context, meaning that they
write to the same destination file/stream.
Diffstat (limited to 'test')
-rw-r--r-- | test/cairo-test-trace.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/cairo-test-trace.c b/test/cairo-test-trace.c index 3be54027..c35d6a7e 100644 --- a/test/cairo-test-trace.c +++ b/test/cairo-test-trace.c @@ -864,14 +864,17 @@ static void write_trace (const char *trace, struct slave *slave) { #if CAIRO_HAS_SCRIPT_SURFACE + cairo_script_context_t *ctx; cairo_surface_t *script; char *filename; cairo_status_t status; xasprintf (&filename, "%s-fail.trace", trace); - script = cairo_script_surface_create (filename, + ctx = cairo_script_context_create (filename); + script = cairo_script_surface_create (ctx, slave->width, slave->height); + cairo_script_context_destroy (ctx); free (filename); status = cairo_meta_surface_replay (slave->image, script); |