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

Comparing ray/src/rt/rtrace.c (file contents):
Revision 2.11 by greg, Wed Jan 20 15:19:51 1993 UTC vs.
Revision 2.13 by greg, Mon Mar 8 12:37:33 1993 UTC

# Line 75 | Line 75 | static RAY  thisray;                   /* for our convenience */
75   static int  oputo(), oputd(), oputv(), oputl(), oputL(),
76                  oputp(), oputn(), oputN(), oputs(), oputw(), oputm();
77  
78 + static int  ourtrace(), tabin();
79   static int  (*ray_out[10])(), (*every_out[10])();
80   static int  castonly;
81  
# Line 139 | Line 140 | char  *fname;
140          default:
141                  error(CONSISTENCY, "botched output format");
142          }
143 <        if (hresolu > 0 && vresolu > 0)
144 <                fprtresolu(hresolu, vresolu, stdout);
143 >        if (hresolu > 0) {
144 >                if (vresolu > 0)
145 >                        fprtresolu(hresolu, vresolu, stdout);
146 >                fflush(stdout);
147 >        }
148                                          /* process file */
149          while (getvec(orig, inform, fp) == 0 &&
150                          getvec(direc, inform, fp) == 0) {
# Line 165 | Line 169 | char  *fname;
169                  if (--vcount == 0)                      /* check for end */
170                          break;
171          }
172 +        fflush(stdout);
173          if (vcount > 0)
174                  error(USER, "read error");
175 <        fclose(fp);
175 >        if (fname != NULL)
176 >                fclose(fp);
177   }
178  
179  
180   setoutput(vs)                           /* set up output tables */
181   register char  *vs;
182   {
183 <        extern int  ourtrace(), (*trace)();
183 >        extern int  (*trace)();
184          register int (**table)() = ray_out;
185  
186          castonly = 1;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines