57 |
|
getfunc(op, 4, 0x3<<5, 0); |
58 |
|
return(1); |
59 |
|
case PAT_CDATA: /* color data */ |
60 |
+ |
if (op->oargs.nsargs < 4) |
61 |
+ |
goto sargerr; |
62 |
|
dp = getdata(op->oargs.sarg[3]); |
63 |
|
getdata(op->oargs.sarg[4]); |
64 |
|
getdata(op->oargs.sarg[5]); |
76 |
|
case PAT_CFUNC: /* color function */ |
77 |
|
getfunc(op, 3, 0x7, 0); |
78 |
|
return(1); |
79 |
+ |
case PAT_SPECFUNC: /* spectral function */ |
80 |
+ |
getfunc(op, 1, 0, 0); |
81 |
+ |
return(1); |
82 |
+ |
case PAT_SPECFILE: /* spectrum file */ |
83 |
+ |
if (op->oargs.nsargs < 1) |
84 |
+ |
goto sargerr; |
85 |
+ |
getdata(op->oargs.sarg[0]); |
86 |
+ |
return(1); |
87 |
+ |
case PAT_SPECDATA: /* spectral data file */ |
88 |
+ |
if (op->oargs.nsargs < 2) |
89 |
+ |
goto sargerr; |
90 |
+ |
dp = getdata(op->oargs.sarg[1]); |
91 |
+ |
getfunc(op, 2, ((1<<(dp->nd-1)) - 1)<<3, 0); |
92 |
+ |
return(1); |
93 |
+ |
case PAT_SPECPICT: /* spectral picture */ |
94 |
+ |
if (op->oargs.nsargs < 2) |
95 |
+ |
goto sargerr; |
96 |
+ |
getspec(op->oargs.sarg[1]); |
97 |
+ |
getfunc(op, 2, 0x3<<3, 0); |
98 |
+ |
return(1); |
99 |
|
case TEX_DATA: /* texture data */ |
100 |
|
if (op->oargs.nsargs < 6) |
101 |
|
goto sargerr; |
130 |
|
goto sargerr; |
131 |
|
getfunc(op, 5, 0x1d, 1); |
132 |
|
sd = loadBSDF(op->oargs.sarg[1]); |
133 |
+ |
if (sd != NULL) SDfreeCache(sd); |
134 |
+ |
return(1); |
135 |
+ |
case MAT_ABSDF: /* aBSDF material */ |
136 |
+ |
if (op->oargs.nsargs < 5) |
137 |
+ |
goto sargerr; |
138 |
+ |
getfunc(op, 4, 0xe, 1); |
139 |
+ |
sd = loadBSDF(op->oargs.sarg[0]); |
140 |
|
if (sd != NULL) SDfreeCache(sd); |
141 |
|
return(1); |
142 |
|
case MAT_PDATA: /* plastic BRDF data */ |