From 5596f4fefe7a36b066df752f939b5a23a71a7bae Mon Sep 17 00:00:00 2001 From: giraffedata Date: Sun, 2 Jun 2013 03:38:21 +0000 Subject: cleanup git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1923 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- converter/ppm/411toppm.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'converter/ppm') diff --git a/converter/ppm/411toppm.c b/converter/ppm/411toppm.c index c87d05a9..eb2372a5 100644 --- a/converter/ppm/411toppm.c +++ b/converter/ppm/411toppm.c @@ -192,6 +192,7 @@ YUVtoPPM(FILE * const ifP, int main(int argc, const char **argv) { + pixval const maxval = 255; struct CmdlineInfo cmdline; FILE * ifP; pixel * pixrow; @@ -208,11 +209,11 @@ main(int argc, const char **argv) { ifP = pm_openr(cmdline.inputFileName); - ppm_writeppminit(stdout, cmdline.width, cmdline.height, 255, 0); + ppm_writeppminit(stdout, cmdline.width, cmdline.height, maxval, 0); - for (row = 0; row < cmdline.height; row++) { + for (row = 0; row < cmdline.height; ++row) { YUVtoPPM(ifP, cmdline.width, cmdline.height, pixrow); - ppm_writeppmrow(stdout, pixrow, cmdline.width, 255, 0); + ppm_writeppmrow(stdout, pixrow, cmdline.width, maxval, 0); } if (fgetc(ifP) != EOF) -- cgit 1.4.1