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

Comparing ray/src/common/ccolor.h (file contents):
Revision 3.3 by greg, Thu May 17 17:10:23 2012 UTC vs.
Revision 3.4 by greg, Thu May 17 21:16:02 2012 UTC

# Line 43 | Line 43 | typedef struct {
43                          C_CMAXV,C_CMAXV,C_CMAXV,C_CMAXV,C_CMAXV,C_CMAXV},\
44                          (long)C_CNSS*C_CMAXV, 1./3., 1./3., 178.006 }
45  
46 < #define c_cval(c,l)     ((double)(c)->ssamp[((l)-C_MINWL)/C_CWLI] / (c)->ssum)
46 > #define c_cval(c,l)     ((c)->ssamp[((l)+(C_CWLI/2.-C_MINWL))/C_CWLI] \
47 >                                                / (double)(c)->ssum)
48  
49   extern C_COLOR          c_dfcolor;              /* default color */
50  
51 +                                                /* set CIE (x,y) chromaticity */
52 + #define c_cset(c,x,y)   ((c)->cx=(x),(c)->cy=(y),(c)->flags=C_CDXY|C_CSXY)
53 +
54 +                                                /* set black body spectrum */
55 + extern int      c_bbtemp(C_COLOR *clr, double tk);
56                                                  /* assign arbitrary spectrum */
57   extern double   c_sset(C_COLOR *clr, double wlmin, double wlmax,
58                                  const float spec[], int nwl);
# Line 58 | Line 64 | extern void    c_cmix(C_COLOR *cres, double w1, C_COLOR *
64                                                  /* multiply two colors */
65   extern double   c_cmult(C_COLOR *cres, C_COLOR *c1, double y1,
66                                  C_COLOR *c2, double y2);
61                                                /* set black body spectrum */
62 extern int      c_bbtemp(C_COLOR *clr, double tk);
67                                                  /* convert to RGB color */
68   extern void     ccy2rgb(C_COLOR *cin, double cieY, float cout[3]);
69                                                  /* convert from RGB color */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines