summaryrefslogtreecommitdiff
path: root/apps/win_main.c
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2010-06-29 21:56:34 +0200
committerRobin Watts <robin.watts@artifex.com>2010-06-29 21:56:34 +0200
commit7748021cc09a52fbb12fc33d7e84806890394249 (patch)
tree692a594b52bb72b55247a0db7b1095783d552b17 /apps/win_main.c
parentd9661dcb35f70cbd5019db4320cd24d6dbae584a (diff)
downloadmupdf-7748021cc09a52fbb12fc33d7e84806890394249.tar.xz
Move over to RGBA instead of ARGB. Add missing gray-alpha 'duff' functions.
Diffstat (limited to 'apps/win_main.c')
-rw-r--r--apps/win_main.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/apps/win_main.c b/apps/win_main.c
index e4c78983..ae12c673 100644
--- a/apps/win_main.c
+++ b/apps/win_main.c
@@ -396,9 +396,9 @@ void winconvert(fz_pixmap *image)
unsigned char *s = image->samples + y * image->w * 4;
for (x = 0; x < image->w; x++)
{
- p[x * 3 + 0] = s[x * 4 + 3];
- p[x * 3 + 1] = s[x * 4 + 2];
- p[x * 3 + 2] = s[x * 4 + 1];
+ p[x * 3 + 0] = s[x * 4 + 2];
+ p[x * 3 + 1] = s[x * 4 + 1];
+ p[x * 3 + 2] = s[x * 4 + 0];
}
}
}
@@ -410,9 +410,9 @@ void winconvert(fz_pixmap *image)
unsigned char *s = image->samples + y * image->w * 2;
for (x = 0; x < image->w; x++)
{
- p[x * 3 + 0] = s[x * 2 + 1];
- p[x * 3 + 1] = s[x * 2 + 1];
- p[x * 3 + 2] = s[x * 2 + 1];
+ p[x * 3 + 0] = s[x * 2];
+ p[x * 3 + 1] = s[x * 2];
+ p[x * 3 + 2] = s[x * 2];
}
}
}