--- ray/src/rt/srcsupp.c 1991/07/18 14:43:07 1.10 +++ ray/src/rt/srcsupp.c 1991/08/26 10:11:08 1.12 @@ -392,7 +392,7 @@ register RAY *r; first = 0; last = nsources-1; } for (i = first; i <= last; i++) - if (source[i].sflags & SDISTANT) + if ((source[i].sflags & (SDISTANT|SVIRTUAL)) == SDISTANT) /* * Check to see if ray is within * solid angle of source. @@ -415,9 +415,10 @@ register RAY *r; } -#define wrongsource(m, r) (m->otype!=MAT_ILLUM && \ - r->rsrc>=0 && \ - source[r->rsrc].so!=r->ro) +#define wrongsource(m, r) (r->rsrc>=0 && \ + source[r->rsrc].so!=r->ro && \ + (m->otype!=MAT_ILLUM || \ + objptr(source[r->rsrc].so->omod)->otype==MAT_ILLUM)) #define distglow(m, r) (m->otype==MAT_GLOW && \ r->rot > m->oargs.farg[3])