From d71ea260f6f9250abc2c358e2c4be0581763a7e3 Mon Sep 17 00:00:00 2001 From: Robin Watts Date: Fri, 20 Jan 2012 18:33:48 +0000 Subject: Bitmap 'patch' scaling - second attempt. When scaling a bitmap, currently we always scale the entire bitmap, even if we only need a small section of the result. This patch changes the code to take an optional 'clip' bbox, and only scales as many pixels as are required to generate the required output region. --- fitz/fitz.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fitz/fitz.h') diff --git a/fitz/fitz.h b/fitz/fitz.h index 3971f24c..49db7dc2 100644 --- a/fitz/fitz.h +++ b/fitz/fitz.h @@ -953,7 +953,7 @@ void fz_invert_pixmap(fz_pixmap *pix); void fz_gamma_pixmap(fz_pixmap *pix, float gamma); unsigned int fz_pixmap_size(fz_pixmap *pix); -fz_pixmap *fz_scale_pixmap(fz_context *ctx, fz_pixmap *src, float x, float y, float w, float h); +fz_pixmap *fz_scale_pixmap(fz_context *ctx, fz_pixmap *src, float x, float y, float w, float h, fz_bbox *clip); void fz_write_pnm(fz_context *ctx, fz_pixmap *pixmap, char *filename); void fz_write_pam(fz_context *ctx, fz_pixmap *pixmap, char *filename, int savealpha); -- cgit v1.2.3