From f18950920cef3964c49276c0241b13cd97c42c5a Mon Sep 17 00:00:00 2001 From: giraffedata Date: Wed, 8 Nov 2023 20:43:38 +0000 Subject: cleanup git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@4781 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- editor/specialty/pnmindex.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/editor/specialty/pnmindex.c b/editor/specialty/pnmindex.c index 4cd467b0..f5b7306c 100644 --- a/editor/specialty/pnmindex.c +++ b/editor/specialty/pnmindex.c @@ -2,7 +2,7 @@ pnmindex ============================================================================== - build a visual index of a bunch of PNM images + Build a visual index of a bunch of PNM images. This used to be a C shell program, and then a BASH program. Neither were portable enough, and the program is too complex for either of @@ -390,7 +390,7 @@ copyScaleQuantImage(const char * const inputFileName, case PBM_TYPE: pm_asprintf(&scaleCommand, "pamscale -quiet -xysize %u %u %s " - "| pgmtopbm > %s", + "| pamditherbw > %s", size, size, inputFileNmToken, outputFileName); break; @@ -525,11 +525,12 @@ makeThumbnail(const char * const inputFileName, unsigned int const col, int * const formatP) { + const char * const fileName = thumbnailFileName(tempDir, row, col); + FILE * ifP; int imageCols, imageRows, format; xelval maxval; const char * tmpfile; - const char * fileName; ifP = pm_openr(inputFileName); pnm_readpnminit(ifP, &imageCols, &imageRows, &maxval, &format); @@ -543,8 +544,6 @@ makeThumbnail(const char * const inputFileName, copyScaleQuantImage(inputFileName, tmpfile, format, size, quant, colorCt); - fileName = thumbnailFileName(tempDir, row, col); - makeImageFile(tmpfile, inputFileName, black, fileName); unlink(tmpfile); -- cgit 1.4.1