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

Comparing ray/src/px/pcond2.c (file contents):
Revision 3.1 by greg, Thu Oct 3 16:52:49 1996 UTC vs.
Revision 3.2 by greg, Fri Oct 4 16:10:41 1996 UTC

# Line 62 | Line 62 | nextscan()                             /* read and condition next scanline */
62   #endif
63                  return(NULL);
64          }
65 <        if (freadscan(scanbuf, scanlen(&inpres), infp) < 0) {
65 >        if (what2do&DO_ACUITY)
66 >                acuscan(scanbuf, nread);
67 >        else if (freadscan(scanbuf, scanlen(&inpres), infp) < 0) {
68                  fprintf(stderr, "%s: %s: scanline read error\n",
69                                  progname, infn);
70                  exit(1);
71          }
70        nread++;
72          if (what2do&DO_VEIL)                    /* add veiling */
73 <                addveil(scanbuf, nread-1);
73 >                addveil(scanbuf, nread);
74          if (what2do&DO_COLOR)                   /* scotopic color loss */
75                  scotscan(scanbuf, scanlen(&inpres));
76          if (what2do&DO_LINEAR)                  /* map luminances */
# Line 80 | Line 81 | nextscan()                             /* read and condition next scanline */
81                  mbscan(scanbuf, scanlen(&inpres), &mbcond);
82          else if (lumf == cielum | inprims != outprims)
83                  matscan(scanbuf, scanlen(&inpres), mbcond.cmat);
84 +        nread++;
85          return(scanbuf);
86   }
87  
# Line 94 | Line 96 | firstscan()                            /* return first processed scanline */
96                          comprgb2rgbmat(mbcond.cmat, inprims, outprims);
97                  else
98                          compxyz2rgbmat(mbcond.cmat, outprims);
99 +        if (what2do&DO_ACUITY) {
100 + #ifdef DEBUG
101 +                fprintf(stderr, "%s: initializing acuity sampling...",
102 +                                progname);
103 + #endif
104 +                initacuity();
105 + #ifdef DEBUG
106 +                fprintf(stderr, "done\n");
107 + #endif
108 +        }
109          scanbuf = (COLOR *)malloc(scanlen(&inpres)*sizeof(COLOR));
110          if (scanbuf == NULL)
111                  syserror("malloc");

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines