36 |
|
int directrelay = 0; /* number of source relays */ |
37 |
|
int vspretest = 128; /* virtual source pretest density */ |
38 |
|
int directinvis = 0; /* sources invisible? */ |
39 |
+ |
double srcsizerat = 0.; /* maximum ratio source size/dist. */ |
40 |
|
|
41 |
|
int maxdepth = 4; /* maximum recursion depth */ |
42 |
|
double minweight = 1e-2; /* minimum ray weight */ |
63 |
|
|
64 |
|
static char *reserve_mem = NULL; /* pre-allocated reserve memory */ |
65 |
|
|
66 |
< |
#define RESERVE_AMT 8192 /* amount of memory to reserve */ |
66 |
> |
#define RESERVE_AMT 32768 /* amount of memory to reserve */ |
67 |
|
|
68 |
|
#define CTRL(c) ('c'-'@') |
69 |
|
|
317 |
|
/* sample the image */ |
318 |
|
for (y = 0; /* y < ysiz */ ; y++) { |
319 |
|
for (x = 0; x < xsiz-1; x++) { |
320 |
< |
if (dev->inpready) |
320 |
> |
if (dev->inpready || errno == ENOMEM) |
321 |
|
goto escape; |
322 |
|
/* |
323 |
|
* Test super-pixel to the right. |
333 |
|
if (y >= ysiz-1) |
334 |
|
break; |
335 |
|
for (x = 0; x < xsiz; x++) { |
336 |
< |
if (dev->inpready) |
336 |
> |
if (dev->inpready || errno == ENOMEM) |
337 |
|
goto escape; |
338 |
|
/* |
339 |
|
* Find super-pixel at this position in next row. |
388 |
|
if (p->kid == NULL) { /* subdivide */ |
389 |
|
|
390 |
|
if ((p->kid = newptree()) == NULL) |
391 |
< |
return(growth); |
391 |
> |
return(0); |
392 |
|
/* |
393 |
|
* The following paint order can leave a black pixel |
394 |
|
* when redraw() is called in (*dev->paintr)(). |