ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/ambcomp.c
(Generate patch)

Comparing ray/src/rt/ambcomp.c (file contents):
Revision 2.63 by greg, Thu Jun 19 16:26:55 2014 UTC vs.
Revision 2.64 by greg, Tue Aug 19 15:04:40 2014 UTC

# Line 78 | Line 78 | ambsample(                             /* initial ambient division sample */
78          hlist[1] = j;
79          hlist[2] = i;
80          multisamp(spt, 2, urand(ilhash(hlist,3)+n));
81 <        if (!n) {                       /* avoid border samples for n==0 */
81 >                                        /* avoid coincident samples */
82 >        if (!n && (0 < i) & (i < hp->ns-1) &&
83 >                        (0 < j) & (j < hp->ns-1)) {
84                  if ((spt[0] < 0.1) | (spt[0] >= 0.9))
85                          spt[0] = 0.1 + 0.8*frandom();
86                  if ((spt[1] < 0.1) | (spt[1] >= 0.9))

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines