ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/px/ra_ppm.c
(Generate patch)

Comparing ray/src/px/ra_ppm.c (file contents):
Revision 2.13 by greg, Fri Jan 6 06:40:53 2006 UTC vs.
Revision 2.16 by greg, Tue Mar 20 18:45:04 2018 UTC

# Line 11 | Line 11 | static const char      RCSid[] = "$Id$";
11   #include  <time.h>
12  
13   #include  "platform.h"
14 + #include  "rtio.h"
15   #include  "color.h"
16   #include  "resolu.h"
17  
# Line 103 | Line 104 | main(
104                  if (read(fileno(stdin), inpbuf, 2) != 2 || inpbuf[0] != 'P')
105                          quiterr("input not a Poskanzer Pixmap");
106                  ptype = inpbuf[1];
107 < #ifdef _WIN32
107 > #if defined(_WIN32) || defined(_WIN64)
108                  if (ptype > 4)
109                          SET_FILE_BINARY(stdin);
110                  SET_FILE_BINARY(stdout);
# Line 153 | Line 154 | main(
154                                  quiterr("unsupported Pixmap type");
155                          }
156          } else {
157 < #ifdef _WIN32
157 > #if defined(_WIN32) || defined(_WIN64)
158                  SET_FILE_BINARY(stdin);
159                  if (binflag)
160                          SET_FILE_BINARY(stdout);
# Line 587 | Line 588 | getby2(                        /* return 2-byte quantity from fp */
588  
589          upperb = getc(fp);
590          lowerb = getc(fp);
591 <        if (upperb == EOF)
591 >        if (lowerb == EOF)
592                  return(EOF);
593          return(upperb<<8 | lowerb);
594   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines