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

Comparing ray/src/common/otypes.h (file contents):
Revision 2.19 by greg, Tue Jun 26 14:42:18 2018 UTC vs.
Revision 2.20 by greg, Wed Nov 15 18:02:52 2023 UTC

# Line 78 | Line 78 | extern int  o_default(); /* XXX conflict with radogl.h
78   #define  MAT_DIRECT1    50              /* unidirecting material */
79   #define  MAT_DIRECT2    51              /* bidirecting material */
80   #define  MAT_ASHIKHMIN  52              /* Ashikhmin-Shirley BRDF material */
81 + #define  PAT_SPECTRUM   53              /* constant spectrum */
82 + #define  PAT_SPECFILE   54              /* spectrum file */
83 + #define  PAT_SPECFUNC   55              /* spectral function */
84                                  /* number of object types */
85 < #define  NUMOTYPE       53
85 > #define  NUMOTYPE       56
86                                  /* type flags */
87   #define  T_S            01              /* surface (object) */
88   #define  T_M            02              /* material */
# Line 110 | Line 113 | extern FUN  ofun[];                    /* our type list */
113   #define  islight(t)     (ofun[t].flags & T_L)
114   #define  isvlight(t)    (ofun[t].flags & T_LV)
115   #define  hasdata(t)     (ofun[t].flags & (T_D|T_I))
116 < #define  hasfunc(t)     (ofun[t].flags & (T_F|T_D|T_I))
116 > #define  hasfunc(t)     (ofun[t].flags & (T_F|T_D|T_I) && (t)!=PAT_SPECFILE)
117   #define  hastext(t)     (ofun[t].flags & T_E)
118 < #define  isflat(t)      ((t)==OBJ_FACE || (t)==OBJ_RING)
118 > #define  isflat(t)      (((t)==OBJ_FACE) | ((t)==OBJ_RING))
119  
120   #define  ALIASKEY       "alias"                 /* alias keyword */
121   #define  ALIASMOD       "inherit"               /* inherit target modifier */
# Line 171 | Line 174 | extern FUN  ofun[];                    /* our type list */
174                                  { "prism1",     T_M|T_F|T_LV,   o_default }, \
175                                  { "prism2",     T_M|T_F|T_LV,   o_default }, \
176                                  { "ashik2",     T_M|T_F,        o_default }, \
177 +                                { "spectrum",   T_P,            o_default }, \
178 +                                { "specfile",   T_P|T_D,        o_default }, \
179 +                                { "specfunc",   T_P|T_F,        o_default }, \
180                          }
181  
182  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines