ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/otspecial.h
Revision: 2.11
Committed: Mon Dec 9 00:44:29 2024 UTC (4 months, 3 weeks ago) by greg
Content type: text/plain
Branch: MAIN
CVS Tags: HEAD
Changes since 2.10: +13 -10 lines
Log Message:
feat: Added new WGMDfunc programmable material

File Contents

# User Rev Content
1 greg 2.11 /* RCSid $Id: otspecial.h,v 2.10 2019/04/18 22:37:36 greg Exp $ */
2 greg 1.1 /*
3     * Special type flags for objects used in rendering.
4     * Depends on definitions in otypes.h
5 greg 2.2 */
6 schorsch 2.4 #ifndef _RAD_OTSPECIAL_H_
7     #define _RAD_OTSPECIAL_H_
8 greg 2.11
9 schorsch 2.4 #ifdef __cplusplus
10     extern "C" {
11     #endif
12 greg 2.11 /* test for nominally transparent materials */
13 greg 2.8 #define T_TRANSP T_SP1
14 greg 2.11 #define istransp(m) (ofun[(m)->otype].flags & T_TRANSP || \
15     (((m)->otype==MAT_WGMDF) & ((m)->oargs.nsargs > 5) \
16     && strcmp((m)->oargs.sarg[5], "0")))
17 greg 2.6
18 greg 2.11 /* test for completely opaque materials */
19 greg 2.6 #define T_OPAQUE T_SP2
20 greg 2.11 #define isopaque(m) (ofun[(m)->otype].flags & T_OPAQUE || \
21     (((m)->otype==MAT_WGMDF) & ((m)->oargs.nsargs > 5) \
22     && !strcmp((m)->oargs.sarg[5], "0")))
23 greg 2.7
24 greg 2.8 /* test if we have a BSDF proxy surface */
25 greg 2.11 #define isBSDFproxy(m) (((m)->otype==MAT_BSDF) & ((m)->oargs.nsargs > 0) \
26     && strcmp((m)->oargs.sarg[0], "0"))
27 schorsch 2.4
28 greg 2.9 /* defined in initotypes.c */
29     extern OBJREC *findmaterial(OBJREC *o);
30    
31 schorsch 2.4 #ifdef __cplusplus
32     }
33     #endif
34 greg 2.11
35 schorsch 2.4 #endif /* _RAD_OTSPECIAL_H_ */