diff options
author | Robin Watts <robin.watts@artifex.com> | 2015-06-26 18:45:26 +0100 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2015-06-29 12:15:18 +0100 |
commit | 2bb213c70d42e398ef7ea3b6551c8fbb865cf3bd (patch) | |
tree | 450c7583241f2236c82fb8ae5bedbb1c0d664ec3 /include/mupdf/fitz/image.h | |
parent | 051b4932219bed310e17505b2e73029d371a18ce (diff) | |
download | mupdf-2bb213c70d42e398ef7ea3b6551c8fbb865cf3bd.tar.xz |
Further tweaks to fz_image handling.
Ensure that subsampling and caching happen in the generic image
code, not in the specific.
Previously, the subsampling happened only for images that were
decoded from streams. Images that were loaded direct were never
subsampled and hence were always cached at full size. After this
change both classes of image are correctly subsampled, and
the subsampled version kept in the cache.
This produces various image diffs in the cluster, none of which
are noticable to the naked eye.
Diffstat (limited to 'include/mupdf/fitz/image.h')
-rw-r--r-- | include/mupdf/fitz/image.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/mupdf/fitz/image.h b/include/mupdf/fitz/image.h index 9c9a9ac4..c788dad3 100644 --- a/include/mupdf/fitz/image.h +++ b/include/mupdf/fitz/image.h @@ -58,7 +58,7 @@ fz_image *fz_new_image_from_data(fz_context *ctx, unsigned char *data, int len); fz_image *fz_new_image_from_buffer(fz_context *ctx, fz_buffer *buffer); fz_pixmap *fz_image_get_pixmap(fz_context *ctx, fz_image *image, int w, int h); void fz_drop_image_imp(fz_context *ctx, fz_storable *image); -fz_pixmap *fz_decomp_image_from_stream(fz_context *ctx, fz_stream *stm, fz_image *image, int indexed, int l2factor, int native_l2factor); +fz_pixmap *fz_decomp_image_from_stream(fz_context *ctx, fz_stream *stm, fz_image *image, int indexed, int l2factor); fz_pixmap *fz_expand_indexed_pixmap(fz_context *ctx, fz_pixmap *src); struct fz_image_s @@ -67,7 +67,7 @@ struct fz_image_s int w, h, n, bpc; fz_image *mask; fz_colorspace *colorspace; - fz_pixmap *(*get_pixmap)(fz_context *, fz_image *, int w, int h, int l2factor); + fz_pixmap *(*get_pixmap)(fz_context *, fz_image *, int w, int h, int *l2factor); int colorkey[FZ_MAX_COLORS * 2]; float decode[FZ_MAX_COLORS * 2]; int imagemask; |