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

Comparing ray/src/common/readoct.c (file contents):
Revision 2.2 by greg, Thu Dec 19 14:45:45 1991 UTC vs.
Revision 2.3 by greg, Thu Mar 12 12:18:18 1992 UTC

# Line 91 | Line 91 | char  *ofn[];
91          if (load & IO_TREE) {
92                                                  /* get the octree */
93                  scene->cutree = gettree();
94 <                                                /* get the scene */
95 <                if (nf == 0 && load & IO_SCENE) {
94 >                if (load & IO_SCENE)            /* get the scene */
95 >                    if (nf == 0) {
96                          for (i = 0; *getstr(sbuf); i++)
97                                  if ((otypmap[i] = otype(sbuf)) < 0) {
98                                          sprintf(errmsg, "unknown type \"%s\"",
# Line 101 | Line 101 | char  *ofn[];
101                                  }
102                          while (getobj() != OVOID)
103                                  ;
104 <                } else if (load & IO_SCENE) {           /* consistency checks */
105 <                                                /* check object count */
104 >                    } else {                    /* consistency checks */
105 >                                        /* check object count */
106                          if (nobjects != objorig+fnobjects)
107                                  octerror(USER, "bad object count; octree stale?");
108 <                                                /* check for non-surfaces */
108 >                                        /* check for non-surfaces */
109                          if (nonsurfinset(objorig, fnobjects))
110 <                                octerror(USER, "non-surface in set; octree stale?");
111 <                }
110 >                                octerror(USER, "modifier in tree; octree stale?");
111 >                    }
112          }
113          fclose(infp);
114          return(nf);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines