summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2011-12-07 22:28:31 +0100
committerRobin Watts <robin.watts@artifex.com>2011-12-08 11:42:57 +0000
commit164ae7a63b56da5a1a2cf63701583753aa433762 (patch)
tree18e376f41142798c49a3849729a84e6a587dc9e2 /apps
parent7a6b60d0ec1abac316917690878011c3228a6fb7 (diff)
downloadmupdf-164ae7a63b56da5a1a2cf63701583753aa433762.tar.xz
Undo pre-multiplied alpha when saving PNG with alpha channels.
Diffstat (limited to 'apps')
-rw-r--r--apps/pdfdraw.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/pdfdraw.c b/apps/pdfdraw.c
index d79cd75c..9ad2b56c 100644
--- a/apps/pdfdraw.c
+++ b/apps/pdfdraw.c
@@ -189,6 +189,9 @@ static void drawpage(pdf_xref *xref, int pagenum)
if (gamma_value != 1)
fz_gamma_pixmap(pix, gamma_value);
+ if (savealpha)
+ fz_unmultiply_pixmap(pix);
+
if (output)
{
char buf[512];