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

Comparing ray/src/px/ra_t8.c (file contents):
Revision 2.4 by greg, Tue Oct 13 11:36:13 1992 UTC vs.
Revision 2.6 by greg, Sun Feb 27 10:17:23 1994 UTC

# Line 125 | Line 125 | char  *argv[];
125                  xmax = head.x;
126                  ymax = head.y;
127                                          /* put header */
128 +                newheader("RADIANCE", stdout);
129                  printargs(i, argv, stdout);
130                  fputformat(COLRFMT, stdout);
131                  putchar('\n');
# Line 391 | Line 392 | int  nc;               /* number of colors to use */
392                          quiterr("error reading Radiance input");
393                  if (bradj)
394                          shiftcolrs(inl, xmax, bradj);
395 +                x = xmax;
396 +                while (x--)
397 +                        inl[x][GRN] = normbright(inl[x]);
398                  colrs_gambs(inl, xmax);
399                  x = xmax;
400                  if (nc < 256)
401                          while (x--)
402 <                                *--dp = ((long)normbright(inl[x])*nc+128)>>8;
402 >                                *--dp = ((long)inl[x][GRN]*nc+nc/2)>>8;
403                  else
404                          while (x--)
405 <                                *--dp = normbright(inl[x]);
405 >                                *--dp = inl[x][GRN];
406          }
407          for (x = 0; x < nc; x++)
408                  clrtab[x][RED] = clrtab[x][GRN] =
409 <                        clrtab[x][BLU] = ((long)x*256+nc/2)/nc;
409 >                        clrtab[x][BLU] = ((long)x*256+128)/nc;
410   }
411  
412  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines