1 |
< |
/* Copyright (c) 1994 Regents of the University of California */ |
1 |
> |
/* Copyright (c) 1995 Regents of the University of California */ |
2 |
|
|
3 |
|
#ifndef lint |
4 |
|
static char SCCSid[] = "$SunId$ LBL"; |
195 |
|
error(USER, errmsg); |
196 |
|
} |
197 |
|
******/ |
198 |
< |
if ((*ofun[m->otype].funp)(m, r)) |
199 |
< |
objerror(r->ro, USER, "conflicting materials"); |
198 |
> |
if ((*ofun[m->otype].funp)(m, r)) { |
199 |
> |
sprintf(errmsg, "conflicting material \"%s\"", |
200 |
> |
m->oname); |
201 |
> |
objerror(r->ro, USER, errmsg); |
202 |
> |
} |
203 |
|
} |
204 |
|
depth--; /* end here */ |
205 |
|
} |
260 |
|
|
261 |
|
|
262 |
|
double |
263 |
+ |
raydist(r, flags) /* compute (cumulative) ray distance */ |
264 |
+ |
register RAY *r; |
265 |
+ |
register int flags; |
266 |
+ |
{ |
267 |
+ |
double sum = 0.0; |
268 |
+ |
|
269 |
+ |
while (r != NULL && r->crtype&flags) { |
270 |
+ |
sum += r->rot; |
271 |
+ |
r = r->parent; |
272 |
+ |
} |
273 |
+ |
return(sum); |
274 |
+ |
} |
275 |
+ |
|
276 |
+ |
|
277 |
+ |
double |
278 |
|
raynormal(norm, r) /* compute perturbed normal for ray */ |
279 |
|
FVECT norm; |
280 |
|
register RAY *r; |
414 |
|
return(0); |
415 |
|
} |
416 |
|
cxset[0] = 0; |
417 |
< |
return(raymove(curpos, cxset, sflags, r, scene) == RAYHIT && |
418 |
< |
r->ro != &Aftplane); |
417 |
> |
raymove(curpos, cxset, sflags, r, scene); |
418 |
> |
return(r->ro != NULL & r->ro != &Aftplane); |
419 |
|
} |
420 |
|
|
421 |
|
|