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

Comparing ray/src/rt/m_bsdf.c (file contents):
Revision 2.25 by greg, Wed Jan 22 16:39:57 2014 UTC vs.
Revision 2.26 by greg, Sat Jan 25 18:27:39 2014 UTC

# Line 457 | Line 457 | m_bsdf(OBJREC *m, RAY *r)
457                          raytrans(r);            /* pass-through */
458                  return(1);                      /* or shadow */
459          }
460 +                                                /* check backface visibility */
461 +        if (!hitfront & !backvis) {
462 +                raytrans(r);
463 +                return(1);
464 +        }
465                                                  /* check other rays to pass */
466          if (nd.thick != 0 && (!(r->crtype & (SPECULAR|AMBIENT)) ||
467                                  nd.thick > 0 ^ hitfront)) {
# Line 474 | Line 479 | m_bsdf(OBJREC *m, RAY *r)
479                                          m->oargs.farg[1],
480                                          m->oargs.farg[2]);
481          } else {
482 <                if (m->oargs.nfargs < 6) {      /* check invisible backside */
478 <                        if (!backvis && (nd.sd->rb == NULL) &
479 <                                        (nd.sd->tb == NULL)) {
480 <                                SDfreeCache(nd.sd);
481 <                                raytrans(r);
482 <                                return(1);
483 <                        }
482 >                if (m->oargs.nfargs < 6)
483                          setcolor(nd.rdiff, .0, .0, .0);
484 <                } else
484 >                else
485                          setcolor(nd.rdiff, m->oargs.farg[3],
486                                          m->oargs.farg[4],
487                                          m->oargs.farg[5]);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines