1 |
+ |
#ifndef lint |
2 |
+ |
static const char RCSid[] = "$Id$"; |
3 |
+ |
#endif |
4 |
|
/* |
5 |
|
================================================================== |
6 |
|
Photon map support routines for emission from light sources |
10 |
|
(c) Lucerne University of Applied Sciences and Arts, |
11 |
|
supported by the Swiss National Science Foundation (SNSF, #147053) |
12 |
|
================================================================== |
13 |
< |
|
11 |
< |
$Id$ |
13 |
> |
|
14 |
|
*/ |
15 |
|
|
16 |
|
|
534 |
|
for (i = 0; i < nobjects; i++) { |
535 |
|
obj = objptr(i); |
536 |
|
|
537 |
< |
if (inset(ambset, obj -> omod)) { |
537 |
> |
/* Check if object is a surface and NOT a light source (duh) and |
538 |
> |
* resolve its material via any aliases, then check for inclusion in |
539 |
> |
* port modifier list */ |
540 |
> |
if (issurface(obj -> otype) && !islight(obj -> otype) && |
541 |
> |
inset(ambset, objndx(findmaterial(obj)))) { |
542 |
|
/* Add photon port */ |
543 |
|
photonPorts = (SRCREC*)realloc(photonPorts, |
544 |
|
(numPhotonPorts + 1) * |