# | Line 491 | Line 491 | sample_sdcomp(BSDFDAT *ndp, SDComponent *dcp, int xmit | |
---|---|---|
491 | multcolor(sr.rcoef, ndp->pr->pcol); | |
492 | if (rayorigin(&sr, SPECULAR, ndp->pr, sr.rcoef) < 0) { | |
493 | if (!n & (nstarget > 1)) { | |
494 | + | n = nstarget; /* avoid infinitue loop */ |
495 | nstarget = nstarget*sr.rweight/minweight; | |
496 | + | if (n == nstarget) break; |
497 | n = -1; /* moved target */ | |
498 | } | |
499 | continue; /* try again */ |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |