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

Comparing ray/src/util/dctimestep.c (file contents):
Revision 2.12 by greg, Thu Jul 1 21:54:56 2010 UTC vs.
Revision 2.13 by greg, Thu Jul 1 22:44:25 2010 UTC

# Line 334 | Line 334 | cm_bsdf(const struct BSDF_data *bsdf)
334  
335   /* Sum together a set of images and write result to stdout */
336   static int
337 < sum_images(const char *fspec, const CMATRIX *cv, FILE *fp)
337 > sum_images(const char *fspec, const CMATRIX *cv, FILE *fout)
338   {
339          int     myDT = DTfromHeader;
340          CMATRIX *pmat;
# Line 372 | Line 372 | sum_images(const char *fspec, const CMATRIX *cv, FILE
372                          pmat = cm_alloc(myYR, myXR);
373                          memset(pmat->cmem, 0, sizeof(COLOR)*myXR*myYR);
374                                                          /* finish header */
375 <                        fputformat(myDT==DTrgbe ? COLRFMT : CIEFMT, fp);
376 <                        fputc('\n', fp);
377 <                        fprtresolu(myXR, myYR, fp);
378 <                        fflush(fp);
375 >                        fputformat(myDT==DTrgbe ? COLRFMT : CIEFMT, fout);
376 >                        fputc('\n', fout);
377 >                        fprtresolu(myXR, myYR, fout);
378 >                        fflush(fout);
379                  } else if ((dt != myDT) | (xr != myXR) | (yr != myYR)) {
380                          sprintf(errmsg, "picture '%s' format/size mismatch",
381                                          fname);
# Line 400 | Line 400 | sum_images(const char *fspec, const CMATRIX *cv, FILE
400          free(scanline);
401                                                          /* write scanlines */
402          for (y = 0; y < myYR; y++)
403 <                if (fwritescan((COLOR *)cm_lval(pmat, y, 0), myXR, fp) < 0)
403 >                if (fwritescan((COLOR *)cm_lval(pmat, y, 0), myXR, fout) < 0)
404                          return(0);
405          cm_free(pmat);                                  /* all done */
406 <        return(fflush(fp) == 0);
406 >        return(fflush(fout) == 0);
407   }
408  
409   /* check to see if a string contains a %d or %o specification */
# Line 435 | Line 435 | main(int argc, char *argv[])
435                  return(1);
436          }
437  
438 <        if (argc > 3) {                         /* need to compute DC matrix? */
438 >        if (argc > 3) {                         /* VTDs expression */
439                  CMATRIX *svec, *Dmat, *Tmat, *ivec;
440                  struct BSDF_data        *btdf;
441                                                  /* get sky vector */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines