From 18f07aea2f40164b3da68f155be1303d09fd2741 Mon Sep 17 00:00:00 2001 From: Sebastian Rasmussen Date: Thu, 13 Oct 2016 21:46:37 +0800 Subject: pnm: Interpret binary b/w image samples correctly. Commit c2acdba7e9b72e18afdd3aa8dfdf66088b1ea1be mistakenly inverted the interpretation of samples for both both binary and ascii b/w PNM images when, at the time, there was only a mistake for ascii images. --- source/fitz/load-pnm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source') diff --git a/source/fitz/load-pnm.c b/source/fitz/load-pnm.c index 8aaecd4f..d9d433c9 100644 --- a/source/fitz/load-pnm.c +++ b/source/fitz/load-pnm.c @@ -354,7 +354,7 @@ pnm_binary_read_image(fz_context *ctx, struct info *pnm, unsigned char *p, unsig { for (x = 0; x < w; x++) { - *dp++ = (*p & (1 << (7 - (x & 0x7)))) ? 0xff : 0x00; + *dp++ = (*p & (1 << (7 - (x & 0x7)))) ? 0x00 : 0xff; if ((x & 0x7) == 7) p++; } -- cgit v1.2.3