diff options
author | Robin Watts <robin.watts@artifex.com> | 2016-05-24 13:50:31 +0100 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2016-05-24 13:51:34 +0100 |
commit | 38c45fc53471720f9c00cc3a09014879da996ba3 (patch) | |
tree | 0a46fad2e98d81faa5106d32a18f278f78c89d21 /source/fitz | |
parent | 9245cd0d2e353262ba518fb9f2e950bb74ad3c3e (diff) | |
download | mupdf-38c45fc53471720f9c00cc3a09014879da996ba3.tar.xz |
Skip alphas for "loaded" JPEGs.
Diffstat (limited to 'source/fitz')
-rw-r--r-- | source/fitz/load-jpeg.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source/fitz/load-jpeg.c b/source/fitz/load-jpeg.c index 6aac519c..1a155191 100644 --- a/source/fitz/load-jpeg.c +++ b/source/fitz/load-jpeg.c @@ -266,7 +266,7 @@ fz_load_jpeg(fz_context *ctx, unsigned char *rbuf, int rlen) else fz_throw(ctx, FZ_ERROR_GENERIC, "bad number of components in jpeg: %d", cinfo.num_components); - image = fz_new_pixmap(ctx, colorspace, cinfo.output_width, cinfo.output_height, 1); + image = fz_new_pixmap(ctx, colorspace, cinfo.output_width, cinfo.output_height, 0); if (extract_exif_resolution(cinfo.marker_list, &image->xres, &image->yres)) /* XPS prefers EXIF resolution to JFIF density */; @@ -299,7 +299,6 @@ fz_load_jpeg(fz_context *ctx, unsigned char *rbuf, int rlen) { for (k = 0; k < cinfo.output_components; k++) *dp++ = *sp++; - *dp++ = 255; } dp += stride; } |