From 563b657255bada6b1790be6c2ff201bf84137c5f Mon Sep 17 00:00:00 2001 From: giraffedata Date: Sat, 24 Apr 2010 02:01:54 +0000 Subject: Fix bug: 12 bit output when 8 would do git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1198 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- converter/other/pnmtops.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'converter/other/pnmtops.c') diff --git a/converter/other/pnmtops.c b/converter/other/pnmtops.c index b43cb483..1568bd28 100644 --- a/converter/other/pnmtops.c +++ b/converter/other/pnmtops.c @@ -1001,6 +1001,8 @@ computeDepth(xelval const inputMaxval, *bitspersampleP = 2; else if (bitsRequiredByMaxval <= 4) *bitspersampleP = 4; + else if (bitsRequiredByMaxval <= 8) + *bitspersampleP = 8; else { /* Post script level 2 defines a format with 12 bits per sample, but I don't know the details of that format (both RLE and -- cgit 1.4.1