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

Comparing ray/src/gen/mkillum2.c (file contents):
Revision 2.23 by greg, Mon Nov 5 23:40:26 2007 UTC vs.
Revision 2.24 by greg, Wed Dec 5 20:07:34 2007 UTC

# Line 22 | Line 22 | newdist(                       /* allocate & clear distribution array */
22          int siz
23   )
24   {
25 <        if (siz == 0) {
25 >        if (siz <= 0) {
26                  if (distsiz > 0)
27                          free((void *)distarr);
28                  distarr = NULL;
# Line 46 | Line 46 | process_ray(RAY *r, int rv)
46   {
47          COLORV  *colp;
48  
49 <        if (rv == 0)
49 >        if (rv == 0)                    /* no result ready */
50                  return(0);
51          if (rv < 0)
52                  error(USER, "ray tracing process died");
# Line 127 | Line 127 | rounddir(              /* compute uniform spherical direction */
127   }
128  
129  
130 < static void
130 > void
131   flatdir(                /* compute uniform hemispherical direction */
132 <        register FVECT  dv,
132 >        FVECT  dv,
133          double  alt,
134          double  azi
135   )
# Line 413 | Line 413 | my_ring(               /* make an illum ring */
413                          r2 = (dim[1] - alti*nazi + sp[1] - .5)/nazi;
414                          flatdir(dn, r1, r2);
415                          for (j = 0; j < 3; j++)
416 <                        dir[j] = -dn[0]*u[j] - dn[1]*v[j] - dn[2]*co->ad[j];
416 >                                dir[j] = -dn[0]*u[j] - dn[1]*v[j] - dn[2]*co->ad[j];
417                      }
418                                          /* randomize location */
419                      multisamp(sp, 2, urand(h+8371));

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines