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

Comparing ray/src/common/objset.c (file contents):
Revision 2.13 by schorsch, Mon Jul 21 22:30:17 2003 UTC vs.
Revision 2.16 by greg, Wed Feb 22 17:05:36 2006 UTC

# Line 70 | Line 70 | OBJECT  obj;
70          int  upper, lower;
71          register int  cm, i;
72  
73 <        if ((i = os[0]) <= 6) {         /* linear search algorithm */
73 >        if ((i = os[0]) <= 12) {        /* linear search algorithm */
74                  cm = obj;
75                  while (i-- > 0)
76                          if (*++os == cm)
# Line 230 | Line 230 | tryagain:
230          return(ot);
231   memerr:
232          error(SYSTEM, "out of memory in fullnode");
233 <        return NULL; /* pro forma return */
233 >        return 0; /* pro forma return */
234   }
235  
236  
# Line 255 | Line 255 | OCTREE  ot;
255          return;
256   noderr:
257          error(CONSISTENCY, "bad node in objset");
258 }
259
260
261 int
262 dosets(f)                               /* loop through all sets */
263 int     (*f)();
264 {
265        int  res = 0;
266        int  n;
267        register OBJECT  *os;
268
269        for (n = 0; n < OSTSIZ; n++) {
270                if ((os = ostable[n]) == NULL)
271                        continue;
272                while (*os > 0) {
273                        res += (*f)(os);
274                        os += *os + 1;
275                }
276        }
277        return(res);
258   }
259  
260  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines