36 |
|
int psample = 4; /* pixel sample size */ |
37 |
|
double maxdiff = .05; /* max. difference for interpolation */ |
38 |
|
double dstrpix = 0.67; /* square pixel distribution */ |
39 |
– |
int psuper = 2; /* pixel super-sampling rate */ |
39 |
|
|
40 |
|
double dstrsrc = 0.0; /* square source distribution */ |
41 |
|
double shadthresh = .05; /* shadow threshold */ |
64 |
|
|
65 |
|
extern long nrays; /* number of rays traced */ |
66 |
|
|
67 |
< |
#define MAXDIV 32 /* maximum sample size */ |
67 |
> |
#define MAXDIV 15 /* maximum sample size */ |
68 |
|
|
69 |
|
#define pixjitter() (.5+dstrpix*(.5-frandom())) |
70 |
|
|
126 |
|
/* check sampling */ |
127 |
|
if (psample < 1) |
128 |
|
psample = 1; |
129 |
< |
else if (psample > MAXDIV) |
129 |
> |
else if (psample > MAXDIV) { |
130 |
> |
sprintf(errmsg, "pixel sampling reduced from %d to %d", |
131 |
> |
psample, MAXDIV); |
132 |
> |
error(WARNING, errmsg); |
133 |
|
psample = MAXDIV; |
134 |
+ |
} |
135 |
|
/* allocate scanlines */ |
136 |
|
for (i = 0; i <= psample; i++) { |
137 |
|
scanbar[i] = (COLOR *)malloc(hresolu*sizeof(COLOR)); |