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

Comparing ray/src/util/glareval.c (file contents):
Revision 1.11 by greg, Fri Apr 5 14:57:28 1991 UTC vs.
Revision 1.12 by greg, Fri Apr 12 10:28:34 1991 UTC

# Line 177 | Line 177 | FVECT  vd;
177  
178  
179   double
180 < getviewpix(vh, vv)              /* compute single view pixel */
180 > getviewpix(vh, vv, se)          /* compute single view pixel */
181   int     vh, vv;
182 + SPANERR *se;
183   {
184          FVECT   dir;
185          float   rt_buf[6];
186          double  res;
187  
188 <        if (compdir(dir, vh, vv) < 0)
188 >        if (compdir(dir, vh, vv, se) < 0)
189                  return(-1.0);
190          npixinvw++;
191          if ((res = pict_val(dir)) >= 0.0)
# Line 211 | Line 212 | float  *vb;
212          float   rt_buf[6*MAXPIX];       /* rtrace send/receive buffer */
213          register int    n;              /* number of pixels in buffer */
214          short   buf_vh[MAXPIX];         /* pixel positions */
215 +        SPANERR sperr;
216          FVECT   dir;
217          register int    vh;
218  
# Line 219 | Line 221 | float  *vb;
221                  fprintf(stderr, "%s: computing view span at %d...\n",
222                                  progname, vv);
223   #endif
224 +        setspanerr(&sperr, vv);
225          n = 0;
226          for (vh = -hsize; vh <= hsize; vh++) {
227 <                if (compdir(dir, vh, vv) < 0) { /* off viewable region */
227 >                if (compdir(dir, vh, vv, &sperr) < 0) { /* not in view */
228                          vb[vh+hsize] = -1.0;
229                          continue;
230                  }
# Line 295 | Line 298 | char   *s;
298   open_pict(fn)                   /* open picture file */
299   char    *fn;
300   {
298        register int    i;
299
301          if ((pictfp = fopen(fn, "r")) == NULL) {
302                  fprintf("%s: cannot open\n", fn);
303                  exit(1);
# Line 313 | Line 314 | char   *fn;
314  
315   close_pict()                    /* done with picture */
316   {
316        register int    i;
317
317          if (pictfp == NULL)
318                  return;
319          fclose(pictfp);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines