From 93bd1ff05bf315ed11b305d32eb510bd9a9a7e92 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Thu, 16 May 2013 22:29:27 +0200 Subject: Add colorspace context. To prepare for color management, we have to make the device colorspaces per-context and able to be overridden by users. --- doc/example.c | 2 +- doc/multi-threaded.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'doc') diff --git a/doc/example.c b/doc/example.c index d60c7cd6..45cca2ff 100644 --- a/doc/example.c +++ b/doc/example.c @@ -54,7 +54,7 @@ render(char *filename, int pagenumber, int zoom, int rotation) fz_irect bbox; fz_round_rect(&bbox, &bounds); - fz_pixmap *pix = fz_new_pixmap_with_bbox(ctx, fz_device_rgb, &bbox); + fz_pixmap *pix = fz_new_pixmap_with_bbox(ctx, fz_device_rgb(ctx), &bbox); fz_clear_pixmap_with_value(ctx, pix, 0xff); // A page consists of a series of objects (text, line art, images, diff --git a/doc/multi-threaded.c b/doc/multi-threaded.c index 7d6c34a4..ac250198 100644 --- a/doc/multi-threaded.c +++ b/doc/multi-threaded.c @@ -202,7 +202,7 @@ int main(int argc, char **argv) // Create a white pixmap using the correct dimensions. - fz_pixmap *pix = fz_new_pixmap_with_bbox(ctx, fz_device_rgb, fz_round_rect(&rbox, &bbox)); + fz_pixmap *pix = fz_new_pixmap_with_bbox(ctx, fz_device_rgb(ctx), fz_round_rect(&rbox, &bbox)); fz_clear_pixmap_with_value(ctx, pix, 0xff); // Populate the data structure to be sent to the -- cgit v1.2.3