diff options
Diffstat (limited to 'fitz/res_pixmap.c')
-rw-r--r-- | fitz/res_pixmap.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/fitz/res_pixmap.c b/fitz/res_pixmap.c index 60e615ec..c498f974 100644 --- a/fitz/res_pixmap.c +++ b/fitz/res_pixmap.c @@ -83,7 +83,7 @@ fz_new_pixmap(fz_context *ctx, fz_colorspace *colorspace, int w, int h) } fz_pixmap * -fz_new_pixmap_with_bbox(fz_context *ctx, fz_colorspace *colorspace, fz_irect r) +fz_new_pixmap_with_bbox(fz_context *ctx, fz_colorspace *colorspace, fz_bbox r) { fz_pixmap *pixmap = fz_new_pixmap(ctx, colorspace, r.x1 - r.x0, r.y1 - r.y0); pixmap->x = r.x0; @@ -92,7 +92,7 @@ fz_new_pixmap_with_bbox(fz_context *ctx, fz_colorspace *colorspace, fz_irect r) } fz_pixmap * -fz_new_pixmap_with_bbox_and_data(fz_context *ctx, fz_colorspace *colorspace, fz_irect r, unsigned char *samples) +fz_new_pixmap_with_bbox_and_data(fz_context *ctx, fz_colorspace *colorspace, fz_bbox r, unsigned char *samples) { fz_pixmap *pixmap = fz_new_pixmap_with_data(ctx, colorspace, r.x1 - r.x0, r.y1 - r.y0, samples); pixmap->x = r.x0; @@ -100,10 +100,10 @@ fz_new_pixmap_with_bbox_and_data(fz_context *ctx, fz_colorspace *colorspace, fz_ return pixmap; } -fz_irect +fz_bbox fz_pixmap_bbox(fz_context *ctx, fz_pixmap *pix) { - fz_irect bbox; + fz_bbox bbox; bbox.x0 = pix->x; bbox.y0 = pix->y; bbox.x1 = pix->x + pix->w; @@ -111,10 +111,10 @@ fz_pixmap_bbox(fz_context *ctx, fz_pixmap *pix) return bbox; } -fz_irect +fz_bbox fz_pixmap_bbox_no_ctx(fz_pixmap *pix) { - fz_irect bbox; + fz_bbox bbox; bbox.x0 = pix->x; bbox.y0 = pix->y; bbox.x1 = pix->x + pix->w; @@ -164,14 +164,14 @@ fz_clear_pixmap_with_value(fz_context *ctx, fz_pixmap *pix, int value) } void -fz_copy_pixmap_rect(fz_context *ctx, fz_pixmap *dest, fz_pixmap *src, fz_irect r) +fz_copy_pixmap_rect(fz_context *ctx, fz_pixmap *dest, fz_pixmap *src, fz_bbox r) { const unsigned char *srcp; unsigned char *destp; int x, y, w, destspan, srcspan; - r = fz_intersect_irect(r, fz_pixmap_bbox(ctx, dest)); - r = fz_intersect_irect(r, fz_pixmap_bbox(ctx, src)); + r = fz_intersect_bbox(r, fz_pixmap_bbox(ctx, dest)); + r = fz_intersect_bbox(r, fz_pixmap_bbox(ctx, src)); w = r.x1 - r.x0; y = r.y1 - r.y0; if (w <= 0 || y <= 0) @@ -264,12 +264,12 @@ fz_copy_pixmap_rect(fz_context *ctx, fz_pixmap *dest, fz_pixmap *src, fz_irect r } void -fz_clear_pixmap_rect_with_value(fz_context *ctx, fz_pixmap *dest, int value, fz_irect r) +fz_clear_pixmap_rect_with_value(fz_context *ctx, fz_pixmap *dest, int value, fz_bbox r) { unsigned char *destp; int x, y, w, k, destspan; - r = fz_intersect_irect(r, fz_pixmap_bbox(ctx, dest)); + r = fz_intersect_bbox(r, fz_pixmap_bbox(ctx, dest)); w = r.x1 - r.x0; y = r.y1 - r.y0; if (w <= 0 || y <= 0) @@ -380,7 +380,7 @@ fz_invert_pixmap(fz_context *ctx, fz_pixmap *pix) } } -void fz_invert_pixmap_rect(fz_pixmap *image, fz_irect r) +void fz_invert_pixmap_rect(fz_pixmap *image, fz_bbox r) { unsigned char *p; int x0, x1, y0, y1; |