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

Comparing ray/src/common/image.c (file contents):
Revision 2.42 by greg, Wed Jan 24 04:23:06 2018 UTC vs.
Revision 2.43 by greg, Wed Jan 24 04:39:52 2018 UTC

# Line 233 | Line 233 | VIEW  *v,
233   FVECT  p
234   )
235   {
236 +        int     rval;
237          double  d, d2;
238          FVECT  disp;
239  
# Line 307 | Line 308 | FVECT  p
308          }
309          ip[0] = DOT(disp,v->hvec)/v->hn2 + 0.5 - v->hoff;
310          ip[1] = DOT(disp,v->vvec)/v->vn2 + 0.5 - v->voff;
311 < gotall:                                 /* return -1 if behind */
312 <        return(1 - 2*(ip[2] <= 0.0));
311 > gotall:                                 /* return negative if behind */
312 >        rval = 1 - 2*(ip[2] <= 0.0);
313 >        if ((0.0 > ip[0]) | (ip[0] > 1.0) || (0.0 > ip[1]) | (ip[1] > 1.0))
314 >                return 2*rval;          /* +/-2 if outside frame */
315 >        return rval;
316   }
317  
318  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines