diff options
author | Robin Watts <robin.watts@artifex.com> | 2013-02-27 19:01:41 +0000 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2013-02-28 00:28:06 +0000 |
commit | 2f8c9375dc0624aff0bac7f5efe4dcbee78453a4 (patch) | |
tree | affed0191aaca1511b004c5ad4f7b8c9840e1819 /pdf | |
parent | a00b3069c1409a3d24bd3c8998693ac8052d78ef (diff) | |
download | mupdf-2f8c9375dc0624aff0bac7f5efe4dcbee78453a4.tar.xz |
Force colorspaces to match with JPX images.
If the colorspace given in the dictionary of a JPX image differs from
the colorspace given in the image itself, decode to the native image
format, then convert.
This goes a long way towards fixing "1439 - color softmask fails to
draw jpx image.pdf" (aka hivemind.pdf). The lack of transfer function
support hopefully explains the rest.
Diffstat (limited to 'pdf')
-rw-r--r-- | pdf/pdf_image.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pdf/pdf_image.c b/pdf/pdf_image.c index a756b648..f87ba00d 100644 --- a/pdf/pdf_image.c +++ b/pdf/pdf_image.c @@ -335,7 +335,7 @@ pdf_load_image_imp(pdf_document *xref, pdf_obj *rdb, pdf_obj *dict, fz_stream *c fz_pixmap *mask_pixmap; if (image->n != 2) fz_throw(ctx, "soft mask must be grayscale"); - mask_pixmap = fz_alpha_from_gray(ctx, image->tile, 1); + mask_pixmap = fz_alpha_from_gray(ctx, image->tile, 0); fz_drop_pixmap(ctx, image->tile); image->tile = mask_pixmap; } |