| 10 |
|
#include "copyright.h" |
| 11 |
|
|
| 12 |
|
#include "ray.h" |
| 13 |
< |
|
| 13 |
> |
#include "source.h" |
| 14 |
|
#include "otypes.h" |
| 15 |
– |
|
| 15 |
|
#include "otspecial.h" |
| 16 |
+ |
#include "random.h" |
| 17 |
|
|
| 18 |
|
#define MAXCSET ((MAXSET+1)*2-1) /* maximum check set size */ |
| 19 |
|
|
| 20 |
|
unsigned long raynum = 0; /* next unique ray number */ |
| 21 |
|
unsigned long nrays = 0; /* number of calls to localhit */ |
| 22 |
|
|
| 23 |
< |
static FLOAT Lambfa[5] = {PI, PI, PI, 0.0, 0.0}; |
| 23 |
> |
static RREAL Lambfa[5] = {PI, PI, PI, 0.0, 0.0}; |
| 24 |
|
OBJREC Lamb = { |
| 25 |
|
OVOID, MAT_PLASTIC, "Lambertian", |
| 26 |
< |
{0, 5, NULL, Lambfa}, NULL, |
| 26 |
> |
{NULL, Lambfa, 0, 5}, NULL |
| 27 |
|
}; /* a Lambertian surface */ |
| 28 |
|
|
| 29 |
|
OBJREC Aftplane; /* aft clipping plane object */ |
| 30 |
|
|
| 31 |
– |
static int raymove(), checkhit(); |
| 32 |
– |
static void checkset(); |
| 33 |
– |
|
| 34 |
– |
#ifndef MAXLOOP |
| 35 |
– |
#define MAXLOOP 0 /* modifier loop detection */ |
| 36 |
– |
#endif |
| 37 |
– |
|
| 31 |
|
#define RAYHIT (-1) /* return value for intercepted ray */ |
| 32 |
|
|
| 33 |
+ |
static int raymove(FVECT pos, OBJECT *cxs, int dirf, RAY *r, CUBE *cu); |
| 34 |
+ |
static int checkhit(RAY *r, CUBE *cu, OBJECT *cxs); |
| 35 |
+ |
static void checkset(OBJECT *os, OBJECT *cs); |
| 36 |
|
|
| 41 |
– |
int |
| 42 |
– |
rayorigin(r, ro, rt, rw) /* start new ray from old one */ |
| 43 |
– |
register RAY *r, *ro; |
| 44 |
– |
int rt; |
| 45 |
– |
double rw; |
| 46 |
– |
{ |
| 47 |
– |
double re; |
| 37 |
|
|
| 38 |
+ |
extern int |
| 39 |
+ |
rayorigin( /* start new ray from old one */ |
| 40 |
+ |
RAY *r, |
| 41 |
+ |
int rt, |
| 42 |
+ |
const RAY *ro, |
| 43 |
+ |
const COLOR rc |
| 44 |
+ |
) |
| 45 |
+ |
{ |
| 46 |
+ |
double rw, re; |
| 47 |
+ |
/* assign coefficient/weight */ |
| 48 |
+ |
if (rc == NULL) { |
| 49 |
+ |
rw = 1.0; |
| 50 |
+ |
setcolor(r->rcoef, 1., 1., 1.); |
| 51 |
+ |
} else { |
| 52 |
+ |
rw = intens(rc); |
| 53 |
+ |
if (rc != r->rcoef) |
| 54 |
+ |
copycolor(r->rcoef, rc); |
| 55 |
+ |
} |
| 56 |
|
if ((r->parent = ro) == NULL) { /* primary ray */ |
| 57 |
|
r->rlvl = 0; |
| 58 |
|
r->rweight = rw; |
| 65 |
|
r->gecc = seccg; |
| 66 |
|
r->slights = NULL; |
| 67 |
|
} else { /* spawned ray */ |
| 68 |
+ |
if (ro->rot >= FHUGE) { |
| 69 |
+ |
memset(r, 0, sizeof(RAY)); |
| 70 |
+ |
return(-1); /* illegal continuation */ |
| 71 |
+ |
} |
| 72 |
|
r->rlvl = ro->rlvl; |
| 73 |
|
if (rt & RAYREFL) { |
| 74 |
|
r->rlvl++; |
| 88 |
|
r->crtype = ro->crtype | (r->rtype = rt); |
| 89 |
|
VCOPY(r->rorg, ro->rop); |
| 90 |
|
r->rweight = ro->rweight * rw; |
| 91 |
< |
/* estimate absorption */ |
| 91 |
> |
/* estimate extinction */ |
| 92 |
|
re = colval(ro->cext,RED) < colval(ro->cext,GRN) ? |
| 93 |
|
colval(ro->cext,RED) : colval(ro->cext,GRN); |
| 94 |
|
if (colval(ro->cext,BLU) < re) re = colval(ro->cext,BLU); |
| 95 |
< |
if (re > 0.) |
| 96 |
< |
r->rweight *= exp(-re*ro->rot); |
| 95 |
> |
re *= ro->rot; |
| 96 |
> |
if (re > 0.1) { |
| 97 |
> |
if (re > 92.) { |
| 98 |
> |
r->rweight = 0.0; |
| 99 |
> |
} else { |
| 100 |
> |
r->rweight *= exp(-re); |
| 101 |
> |
} |
| 102 |
> |
} |
| 103 |
|
} |
| 104 |
|
rayclear(r); |
| 105 |
< |
return(r->rlvl <= maxdepth && r->rweight >= minweight ? 0 : -1); |
| 105 |
> |
if (r->rweight <= 0.0) /* check for expiration */ |
| 106 |
> |
return(-1); |
| 107 |
> |
if (r->crtype & SHADOW) /* shadow commitment */ |
| 108 |
> |
return(0); |
| 109 |
> |
if (maxdepth <= 0 && rc != NULL) { /* Russian roulette */ |
| 110 |
> |
if (minweight <= 0.0) |
| 111 |
> |
error(USER, "zero ray weight in Russian roulette"); |
| 112 |
> |
if (maxdepth < 0 && r->rlvl > -maxdepth) |
| 113 |
> |
return(-1); /* upper reflection limit */ |
| 114 |
> |
if (r->rweight >= minweight) |
| 115 |
> |
return(0); |
| 116 |
> |
if (frandom() > r->rweight/minweight) |
| 117 |
> |
return(-1); |
| 118 |
> |
rw = minweight/r->rweight; /* promote survivor */ |
| 119 |
> |
scalecolor(r->rcoef, rw); |
| 120 |
> |
r->rweight = minweight; |
| 121 |
> |
return(0); |
| 122 |
> |
} |
| 123 |
> |
return(r->rlvl <= abs(maxdepth) && r->rweight >= minweight ? 0 : -1); |
| 124 |
|
} |
| 125 |
|
|
| 126 |
|
|
| 127 |
< |
void |
| 128 |
< |
rayclear(r) /* clear a ray for (re)evaluation */ |
| 129 |
< |
register RAY *r; |
| 127 |
> |
extern void |
| 128 |
> |
rayclear( /* clear a ray for (re)evaluation */ |
| 129 |
> |
register RAY *r |
| 130 |
> |
) |
| 131 |
|
{ |
| 132 |
|
r->rno = raynum++; |
| 133 |
|
r->newcset = r->clipset; |
| 143 |
|
} |
| 144 |
|
|
| 145 |
|
|
| 146 |
< |
void |
| 147 |
< |
raytrace(r) /* trace a ray and compute its value */ |
| 148 |
< |
RAY *r; |
| 146 |
> |
extern void |
| 147 |
> |
raytrace( /* trace a ray and compute its value */ |
| 148 |
> |
RAY *r |
| 149 |
> |
) |
| 150 |
|
{ |
| 151 |
|
if (localhit(r, &thescene)) |
| 152 |
|
raycont(r); /* hit local surface, evaluate */ |
| 156 |
|
} else if (sourcehit(r)) |
| 157 |
|
rayshade(r, r->ro->omod); /* distant source */ |
| 158 |
|
|
| 122 |
– |
rayparticipate(r); /* for participating medium */ |
| 123 |
– |
|
| 159 |
|
if (trace != NULL) |
| 160 |
|
(*trace)(r); /* trace execution */ |
| 161 |
+ |
|
| 162 |
+ |
rayparticipate(r); /* for participating medium */ |
| 163 |
|
} |
| 164 |
|
|
| 165 |
|
|
| 166 |
< |
void |
| 167 |
< |
raycont(r) /* check for clipped object and continue */ |
| 168 |
< |
register RAY *r; |
| 166 |
> |
extern void |
| 167 |
> |
raycont( /* check for clipped object and continue */ |
| 168 |
> |
register RAY *r |
| 169 |
> |
) |
| 170 |
|
{ |
| 171 |
|
if ((r->clipset != NULL && inset(r->clipset, r->ro->omod)) || |
| 172 |
|
!rayshade(r, r->ro->omod)) |
| 174 |
|
} |
| 175 |
|
|
| 176 |
|
|
| 177 |
< |
void |
| 178 |
< |
raytrans(r) /* transmit ray as is */ |
| 179 |
< |
register RAY *r; |
| 177 |
> |
extern void |
| 178 |
> |
raytrans( /* transmit ray as is */ |
| 179 |
> |
register RAY *r |
| 180 |
> |
) |
| 181 |
|
{ |
| 182 |
|
RAY tr; |
| 183 |
|
|
| 184 |
< |
if (rayorigin(&tr, r, TRANS, 1.0) == 0) { |
| 184 |
> |
if (rayorigin(&tr, TRANS, r, NULL) == 0) { |
| 185 |
|
VCOPY(tr.rdir, r->rdir); |
| 186 |
|
rayvalue(&tr); |
| 187 |
|
copycolor(r->rcol, tr.rcol); |
| 190 |
|
} |
| 191 |
|
|
| 192 |
|
|
| 193 |
< |
int |
| 194 |
< |
rayshade(r, mod) /* shade ray r with material mod */ |
| 195 |
< |
register RAY *r; |
| 196 |
< |
int mod; |
| 193 |
> |
extern int |
| 194 |
> |
rayshade( /* shade ray r with material mod */ |
| 195 |
> |
register RAY *r, |
| 196 |
> |
int mod |
| 197 |
> |
) |
| 198 |
|
{ |
| 159 |
– |
int gotmat; |
| 199 |
|
register OBJREC *m; |
| 200 |
< |
#if MAXLOOP |
| 162 |
< |
static int depth = 0; |
| 163 |
< |
/* check for infinite loop */ |
| 164 |
< |
if (depth++ >= MAXLOOP) |
| 165 |
< |
objerror(r->ro, USER, "possible modifier loop"); |
| 166 |
< |
#endif |
| 200 |
> |
|
| 201 |
|
r->rt = r->rot; /* set effective ray length */ |
| 202 |
< |
for (gotmat = 0; !gotmat && mod != OVOID; mod = m->omod) { |
| 202 |
> |
for ( ; mod != OVOID; mod = m->omod) { |
| 203 |
|
m = objptr(mod); |
| 204 |
|
/****** unnecessary test since modifier() is always called |
| 205 |
|
if (!ismodifier(m->otype)) { |
| 209 |
|
******/ |
| 210 |
|
/* hack for irradiance calculation */ |
| 211 |
|
if (do_irrad && !(r->crtype & ~(PRIMARY|TRANS)) && |
| 212 |
+ |
m->otype != MAT_CLIP && |
| 213 |
|
(ofun[m->otype].flags & (T_M|T_X))) { |
| 214 |
|
if (irr_ignore(m->otype)) { |
| 180 |
– |
#if MAXLOOP |
| 181 |
– |
depth--; |
| 182 |
– |
#endif |
| 215 |
|
raytrans(r); |
| 216 |
|
return(1); |
| 217 |
|
} |
| 218 |
|
if (!islight(m->otype)) |
| 219 |
|
m = &Lamb; |
| 220 |
|
} |
| 221 |
< |
/* materials call raytexture */ |
| 222 |
< |
gotmat = (*ofun[m->otype].funp)(m, r); |
| 221 |
> |
if ((*ofun[m->otype].funp)(m, r)) |
| 222 |
> |
return(1); /* materials call raytexture() */ |
| 223 |
|
} |
| 224 |
< |
#if MAXLOOP |
| 193 |
< |
depth--; |
| 194 |
< |
#endif |
| 195 |
< |
return(gotmat); |
| 224 |
> |
return(0); /* no material! */ |
| 225 |
|
} |
| 226 |
|
|
| 227 |
|
|
| 228 |
< |
void |
| 229 |
< |
rayparticipate(r) /* compute ray medium participation */ |
| 230 |
< |
register RAY *r; |
| 228 |
> |
extern void |
| 229 |
> |
rayparticipate( /* compute ray medium participation */ |
| 230 |
> |
register RAY *r |
| 231 |
> |
) |
| 232 |
|
{ |
| 233 |
|
COLOR ce, ca; |
| 234 |
|
double re, ge, be; |
| 243 |
|
ge *= 1. - colval(r->albedo,GRN); |
| 244 |
|
be *= 1. - colval(r->albedo,BLU); |
| 245 |
|
} |
| 246 |
< |
setcolor(ce, re<=0. ? 1. : re>92. ? 0. : exp(-re), |
| 247 |
< |
ge<=0. ? 1. : ge>92. ? 0. : exp(-ge), |
| 248 |
< |
be<=0. ? 1. : be>92. ? 0. : exp(-be)); |
| 249 |
< |
multcolor(r->rcol, ce); /* path absorption */ |
| 246 |
> |
setcolor(ce, re<=FTINY ? 1. : re>92. ? 0. : exp(-re), |
| 247 |
> |
ge<=FTINY ? 1. : ge>92. ? 0. : exp(-ge), |
| 248 |
> |
be<=FTINY ? 1. : be>92. ? 0. : exp(-be)); |
| 249 |
> |
multcolor(r->rcol, ce); /* path extinction */ |
| 250 |
|
if (r->crtype & SHADOW || intens(r->albedo) <= FTINY) |
| 251 |
|
return; /* no scattering */ |
| 252 |
|
setcolor(ca, |
| 258 |
|
} |
| 259 |
|
|
| 260 |
|
|
| 261 |
< |
raytexture(r, mod) /* get material modifiers */ |
| 262 |
< |
RAY *r; |
| 263 |
< |
int mod; |
| 261 |
> |
extern void |
| 262 |
> |
raytexture( /* get material modifiers */ |
| 263 |
> |
RAY *r, |
| 264 |
> |
OBJECT mod |
| 265 |
> |
) |
| 266 |
|
{ |
| 267 |
|
register OBJREC *m; |
| 236 |
– |
#if MAXLOOP |
| 237 |
– |
static int depth = 0; |
| 238 |
– |
/* check for infinite loop */ |
| 239 |
– |
if (depth++ >= MAXLOOP) |
| 240 |
– |
objerror(r->ro, USER, "modifier loop"); |
| 241 |
– |
#endif |
| 268 |
|
/* execute textures and patterns */ |
| 269 |
|
for ( ; mod != OVOID; mod = m->omod) { |
| 270 |
|
m = objptr(mod); |
| 280 |
|
objerror(r->ro, USER, errmsg); |
| 281 |
|
} |
| 282 |
|
} |
| 257 |
– |
#if MAXLOOP |
| 258 |
– |
depth--; /* end here */ |
| 259 |
– |
#endif |
| 283 |
|
} |
| 284 |
|
|
| 285 |
|
|
| 286 |
< |
int |
| 287 |
< |
raymixture(r, fore, back, coef) /* mix modifiers */ |
| 288 |
< |
register RAY *r; |
| 289 |
< |
OBJECT fore, back; |
| 290 |
< |
double coef; |
| 286 |
> |
extern int |
| 287 |
> |
raymixture( /* mix modifiers */ |
| 288 |
> |
register RAY *r, |
| 289 |
> |
OBJECT fore, |
| 290 |
> |
OBJECT back, |
| 291 |
> |
double coef |
| 292 |
> |
) |
| 293 |
|
{ |
| 294 |
|
RAY fr, br; |
| 295 |
|
int foremat, backmat; |
| 302 |
|
/* compute foreground and background */ |
| 303 |
|
foremat = backmat = 0; |
| 304 |
|
/* foreground */ |
| 305 |
< |
copystruct(&fr, r); |
| 306 |
< |
if (coef > FTINY) |
| 305 |
> |
fr = *r; |
| 306 |
> |
if (coef > FTINY) { |
| 307 |
> |
fr.rweight *= coef; |
| 308 |
> |
scalecolor(fr.rcoef, coef); |
| 309 |
|
foremat = rayshade(&fr, fore); |
| 310 |
+ |
} |
| 311 |
|
/* background */ |
| 312 |
< |
copystruct(&br, r); |
| 313 |
< |
if (coef < 1.0-FTINY) |
| 312 |
> |
br = *r; |
| 313 |
> |
if (coef < 1.0-FTINY) { |
| 314 |
> |
br.rweight *= 1.0-coef; |
| 315 |
> |
scalecolor(br.rcoef, 1.0-coef); |
| 316 |
|
backmat = rayshade(&br, back); |
| 317 |
+ |
} |
| 318 |
|
/* check for transparency */ |
| 319 |
< |
if (backmat ^ foremat) |
| 319 |
> |
if (backmat ^ foremat) { |
| 320 |
|
if (backmat && coef > FTINY) |
| 321 |
|
raytrans(&fr); |
| 322 |
|
else if (foremat && coef < 1.0-FTINY) |
| 323 |
|
raytrans(&br); |
| 324 |
+ |
} |
| 325 |
|
/* mix perturbations */ |
| 326 |
|
for (i = 0; i < 3; i++) |
| 327 |
|
r->pert[i] = coef*fr.pert[i] + (1.0-coef)*br.pert[i]; |
| 343 |
|
} |
| 344 |
|
|
| 345 |
|
|
| 346 |
< |
double |
| 347 |
< |
raydist(r, flags) /* compute (cumulative) ray distance */ |
| 348 |
< |
register RAY *r; |
| 349 |
< |
register int flags; |
| 346 |
> |
extern double |
| 347 |
> |
raydist( /* compute (cumulative) ray distance */ |
| 348 |
> |
register const RAY *r, |
| 349 |
> |
register int flags |
| 350 |
> |
) |
| 351 |
|
{ |
| 352 |
|
double sum = 0.0; |
| 353 |
|
|
| 359 |
|
} |
| 360 |
|
|
| 361 |
|
|
| 362 |
< |
double |
| 363 |
< |
raynormal(norm, r) /* compute perturbed normal for ray */ |
| 364 |
< |
FVECT norm; |
| 365 |
< |
register RAY *r; |
| 362 |
> |
extern void |
| 363 |
> |
raycontrib( /* compute (cumulative) ray contribution */ |
| 364 |
> |
double rc[3], |
| 365 |
> |
const RAY *r, |
| 366 |
> |
int flags |
| 367 |
> |
) |
| 368 |
|
{ |
| 369 |
+ |
double eext[3]; |
| 370 |
+ |
int i; |
| 371 |
+ |
|
| 372 |
+ |
eext[0] = eext[1] = eext[2] = 0.; |
| 373 |
+ |
rc[0] = rc[1] = rc[2] = 1.; |
| 374 |
+ |
|
| 375 |
+ |
while (r != NULL && r->crtype&flags) { |
| 376 |
+ |
for (i = 3; i--; ) { |
| 377 |
+ |
rc[i] *= colval(r->rcoef,i); |
| 378 |
+ |
eext[i] += r->rot * colval(r->cext,i); |
| 379 |
+ |
} |
| 380 |
+ |
r = r->parent; |
| 381 |
+ |
} |
| 382 |
+ |
for (i = 3; i--; ) |
| 383 |
+ |
rc[i] *= (eext[i] <= FTINY) ? 1. : |
| 384 |
+ |
(eext[i] > 92.) ? 0. : exp(-eext[i]); |
| 385 |
+ |
} |
| 386 |
+ |
|
| 387 |
+ |
|
| 388 |
+ |
extern double |
| 389 |
+ |
raynormal( /* compute perturbed normal for ray */ |
| 390 |
+ |
FVECT norm, |
| 391 |
+ |
register RAY *r |
| 392 |
+ |
) |
| 393 |
+ |
{ |
| 394 |
|
double newdot; |
| 395 |
|
register int i; |
| 396 |
|
|
| 421 |
|
} |
| 422 |
|
|
| 423 |
|
|
| 424 |
< |
void |
| 425 |
< |
newrayxf(r) /* get new tranformation matrix for ray */ |
| 426 |
< |
RAY *r; |
| 424 |
> |
extern void |
| 425 |
> |
newrayxf( /* get new tranformation matrix for ray */ |
| 426 |
> |
RAY *r |
| 427 |
> |
) |
| 428 |
|
{ |
| 429 |
|
static struct xfn { |
| 430 |
|
struct xfn *next; |
| 431 |
|
FULLXF xf; |
| 432 |
|
} xfseed = { &xfseed }, *xflast = &xfseed; |
| 433 |
|
register struct xfn *xp; |
| 434 |
< |
register RAY *rp; |
| 434 |
> |
register const RAY *rp; |
| 435 |
|
|
| 436 |
|
/* |
| 437 |
|
* Search for transform in circular list that |
| 459 |
|
} |
| 460 |
|
|
| 461 |
|
|
| 462 |
< |
void |
| 463 |
< |
flipsurface(r) /* reverse surface orientation */ |
| 464 |
< |
register RAY *r; |
| 462 |
> |
extern void |
| 463 |
> |
flipsurface( /* reverse surface orientation */ |
| 464 |
> |
register RAY *r |
| 465 |
> |
) |
| 466 |
|
{ |
| 467 |
|
r->rod = -r->rod; |
| 468 |
|
r->ron[0] = -r->ron[0]; |
| 474 |
|
} |
| 475 |
|
|
| 476 |
|
|
| 477 |
< |
void |
| 478 |
< |
rayhit(oset, r) /* standard ray hit test */ |
| 479 |
< |
OBJECT *oset; |
| 480 |
< |
RAY *r; |
| 477 |
> |
extern void |
| 478 |
> |
rayhit( /* standard ray hit test */ |
| 479 |
> |
OBJECT *oset, |
| 480 |
> |
RAY *r |
| 481 |
> |
) |
| 482 |
|
{ |
| 483 |
|
OBJREC *o; |
| 484 |
|
int i; |
| 491 |
|
} |
| 492 |
|
|
| 493 |
|
|
| 494 |
< |
int |
| 495 |
< |
localhit(r, scene) /* check for hit in the octree */ |
| 496 |
< |
register RAY *r; |
| 497 |
< |
register CUBE *scene; |
| 494 |
> |
extern int |
| 495 |
> |
localhit( /* check for hit in the octree */ |
| 496 |
> |
register RAY *r, |
| 497 |
> |
register CUBE *scene |
| 498 |
> |
) |
| 499 |
|
{ |
| 500 |
|
OBJECT cxset[MAXCSET+1]; /* set of checked objects */ |
| 501 |
|
FVECT curpos; /* current cube position */ |
| 550 |
|
} |
| 551 |
|
cxset[0] = 0; |
| 552 |
|
raymove(curpos, cxset, sflags, r, scene); |
| 553 |
< |
return(r->ro != NULL & r->ro != &Aftplane); |
| 553 |
> |
return((r->ro != NULL) & (r->ro != &Aftplane)); |
| 554 |
|
} |
| 555 |
|
|
| 556 |
|
|
| 557 |
|
static int |
| 558 |
< |
raymove(pos, cxs, dirf, r, cu) /* check for hit as we move */ |
| 559 |
< |
FVECT pos; /* current position, modified herein */ |
| 560 |
< |
OBJECT *cxs; /* checked objects, modified by checkhit */ |
| 561 |
< |
int dirf; /* direction indicators to speed tests */ |
| 562 |
< |
register RAY *r; |
| 563 |
< |
register CUBE *cu; |
| 558 |
> |
raymove( /* check for hit as we move */ |
| 559 |
> |
FVECT pos, /* current position, modified herein */ |
| 560 |
> |
OBJECT *cxs, /* checked objects, modified by checkhit */ |
| 561 |
> |
int dirf, /* direction indicators to speed tests */ |
| 562 |
> |
register RAY *r, |
| 563 |
> |
register CUBE *cu |
| 564 |
> |
) |
| 565 |
|
{ |
| 566 |
|
int ax; |
| 567 |
|
double dt, t; |
| 642 |
|
|
| 643 |
|
|
| 644 |
|
static int |
| 645 |
< |
checkhit(r, cu, cxs) /* check for hit in full cube */ |
| 646 |
< |
register RAY *r; |
| 647 |
< |
CUBE *cu; |
| 648 |
< |
OBJECT *cxs; |
| 645 |
> |
checkhit( /* check for hit in full cube */ |
| 646 |
> |
register RAY *r, |
| 647 |
> |
CUBE *cu, |
| 648 |
> |
OBJECT *cxs |
| 649 |
> |
) |
| 650 |
|
{ |
| 651 |
|
OBJECT oset[MAXSET+1]; |
| 652 |
|
|
| 663 |
|
|
| 664 |
|
|
| 665 |
|
static void |
| 666 |
< |
checkset(os, cs) /* modify checked set and set to check */ |
| 667 |
< |
register OBJECT *os; /* os' = os - cs */ |
| 668 |
< |
register OBJECT *cs; /* cs' = cs + os */ |
| 666 |
> |
checkset( /* modify checked set and set to check */ |
| 667 |
> |
register OBJECT *os, /* os' = os - cs */ |
| 668 |
> |
register OBJECT *cs /* cs' = cs + os */ |
| 669 |
> |
) |
| 670 |
|
{ |
| 671 |
|
OBJECT cset[MAXCSET+MAXSET+1]; |
| 672 |
|
register int i, j; |