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

Comparing ray/src/hd/rhpict.c (file contents):
Revision 3.13 by schorsch, Mon Jul 21 22:30:18 2003 UTC vs.
Revision 3.16 by greg, Wed Oct 22 02:06:34 2003 UTC

# Line 7 | Line 7 | static const char      RCSid[] = "$Id$";
7  
8   #include <string.h>
9  
10 + #include "platform.h"
11   #include "rholo.h"
12   #include "view.h"
13  
# Line 56 | Line 57 | char   *argv[];
57                                  pixaspect = atof(argv[++i]);
58                          else if (argv[i][2] == 'e') {
59                                  expval = atof(argv[++i]);
60 <                                if (argv[i][0] == '-' | argv[i][0] == '+')
60 >                                if ((argv[i][0] == '-') | (argv[i][0] == '+'))
61                                          expval = pow(2., expval);
62                          } else
63                                  goto userr;
# Line 212 | Line 213 | int    fn;
213          fputs(VIEWSTR, stdout);
214          fprintview(&myview, stdout);
215          fputc('\n', stdout);
216 <        if (pa < 0.99 | pa > 1.01)
216 >        if ((pa < 0.99) | (pa > 1.01))
217                  fputaspect(pa, stdout);
218 <        if (expval < 0.99 | expval > 1.01)
218 >        if ((expval < 0.99) | (expval > 1.01))
219                  fputexpos(expval, stdout);
220          fputformat(COLRFMT, stdout);
221          fputc('\n', stdout);
# Line 284 | Line 285 | initialize()                   /* initialize holodeck and buffers */
285          fd = dup(fileno(fp));                   /* dup file descriptor */
286          fclose(fp);                             /* done with stdio */
287          for (n = 0; nextloc > 0L; n++) {        /* initialize each section */
288 <                lseek(fd, (off_t)nextloc, 0);
288 >                lseek(fd, (off_t)nextloc, SEEK_SET);
289                  read(fd, (char *)&nextloc, sizeof(nextloc));
290                  hdinit(fd, NULL);
291          }
# Line 292 | Line 293 | initialize()                   /* initialize holodeck and buffers */
293          mypixel = (COLOR *)bmalloc(xres*yres*sizeof(COLOR));
294          myweight = (float *)bmalloc(xres*yres*sizeof(float));
295          mydepth = (float *)bmalloc(xres*yres*sizeof(float));
296 <        if (mypixel == NULL | myweight == NULL | mydepth == NULL)
296 >        if ((mypixel == NULL) | (myweight == NULL) | (mydepth == NULL))
297                  error(SYSTEM, "out of memory in initialize");
298   }
299  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines