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

Comparing ray/src/rt/pmapmat.c (file contents):
Revision 2.19 by rschregle, Tue Dec 4 21:58:46 2018 UTC vs.
Revision 2.23 by rschregle, Wed Jan 20 19:44:15 2021 UTC

# Line 46 | Line 46 | typedef struct {
46     COLOR    mcolor, scolor;
47     FVECT    vrefl, prdir, pnorm;
48     double   alpha2, rdiff, rspec, trans, tdiff, tspec, pdot;
49 < }  NORMDAT;
49 > } NORMDAT;
50  
51   typedef struct {
52     OBJREC   *mp;
# Line 55 | Line 55 | typedef struct {
55     COLOR    mcolor, scolor;
56     FVECT    vrefl, prdir, u, v, pnorm;
57     double   u_alpha, v_alpha, rdiff, rspec, trans, tdiff, tspec, pdot;
58 < }  ANISODAT;
58 > } ANISODAT;
59  
60   typedef struct {
61     OBJREC   *mp;
# Line 69 | Line 69 | typedef struct {
69     double   tspec;
70     FVECT    pnorm;
71     double   pdot;
72 < }  BRDFDAT;
72 > } BRDFDAT;
73  
74   typedef struct {
75     OBJREC   *mp;
# Line 145 | Line 145 | void photonRay (const RAY *rayIn, RAY *rayOut,
145   }
146  
147  
148
148   static void addPhotons (const RAY *r)
149   /* Insert photon hits, where applicable */
150   {
151     if (!r -> rlvl)
152 <      /* Add direct photon map at primary hitpoint */
152 >      /* Add direct photon at primary hitpoint */
153        newPhoton(directPmap, r);
154     else {
155 <      /* Add global or precomputed photon map at indirect hitpoint */
155 >      /* Add global or precomputed photon at indirect hitpoint */
156        newPhoton(preCompPmap ? preCompPmap : globalPmap, r);
157  
158        /* Store caustic photon if specular flag set */
# Line 319 | Line 318 | static int normalPhotonScatter (OBJREC *mat, RAY *rayI
318        }
319     else raytexture(rayIn, mat -> omod);
320    
321 +   nd.mp = mat;
322     nd.rp = rayIn;
323    
324     /* Get material color */
# Line 480 | Line 480 | static int normalPhotonScatter (OBJREC *mat, RAY *rayI
480  
481  
482  
483 < static void getacoords (ANISODAT *np)
483 > static void getacoords (ANISODAT *nd)
484   /* Set up coordinate system for anisotropic sampling; cloned from aniso.c */
485   {
486 <   MFUNC  *mf;
487 <   int  i;
486 >   MFUNC *mf;
487 >   int   i;
488  
489 <   mf = getfunc(np->mp, 3, 0x7, 1);
490 <   setfunc(np->mp, np->rp);
489 >   mf = getfunc(nd -> mp, 3, 0x7, 1);
490 >   setfunc(nd -> mp, nd -> rp);
491     errno = 0;
492  
493     for (i = 0; i < 3; i++)
494 <      np->u[i] = evalue(mf->ep[i]);
494 >      nd -> u [i] = evalue(mf -> ep [i]);
495    
496 <   if ((errno == EDOM) | (errno == ERANGE)) {
497 <      objerror(np->mp, WARNING, "compute error");
498 <      np->specfl |= SP_BADU;
499 <      return;
500 <   }
501 <  
502 <   if (mf->fxp != &unitxf)
503 <      multv3(np->u, np->u, mf->fxp->xfm);
496 >   if (errno == EDOM || errno == ERANGE)
497 >      nd -> u [0] = nd -> u [1] = nd -> u [2] = 0.0;
498        
499 <   fcross(np->v, np->pnorm, np->u);
499 >   if (mf -> fxp != &unitxf)
500 >      multv3(nd -> u, nd -> u, mf -> fxp -> xfm);
501  
502 <   if (normalize(np->v) == 0.0) {
508 <      objerror(np->mp, WARNING, "illegal orientation vector");
509 <      np->specfl |= SP_BADU;
510 <      return;
511 <   }
502 >   fcross(nd -> v, nd -> pnorm, nd -> u);
503    
504 <   fcross(np->u, np->v, np->pnorm);
504 >   if (normalize(nd -> v) == 0.0) {
505 >      if (fabs(nd -> u_alpha - nd -> v_alpha) > 0.001)
506 >         objerror(nd -> mp, WARNING, "illegal orientation vector");
507 >      getperpendicular(nd -> u, nd -> pnorm, 1);
508 >      fcross(nd -> v, nd -> pnorm, nd -> u);
509 >      nd -> u_alpha = nd -> v_alpha =
510 >         sqrt(0.5 * (sqr(nd -> u_alpha) + sqr(nd -> v_alpha)));
511 >   }
512 >   else fcross(nd -> u, nd -> v, nd -> pnorm);
513   }
514  
515  
# Line 616 | Line 615 | static int anisoPhotonScatter (OBJREC *mat, RAY *rayIn
615     if (mat -> oargs.nfargs != (mat -> otype == MAT_TRANS2 ? 8 : 6))
616        objerror(mat, USER, "bad number of real arguments");
617        
618 +   nd.mp = mat;
619     nd.rp = rayIn;
620   nd.mp = objptr(rayIn -> ro -> omod);
620    
621     /* get material color */
622     copycolor(nd.mcolor, mat -> oargs.farg);
# Line 661 | Line 660 | static int anisoPhotonScatter (OBJREC *mat, RAY *rayIn
660     if (nd.rspec > FTINY) {
661        nd.specfl |= SP_REFL;
662        
663 <      /* comput   e specular color */
663 >      /* compute specular color */
664        if (mat -> otype == MAT_METAL2)
665           copycolor(nd.scolor, nd.mcolor);
666        else setcolor(nd.scolor, 1, 1, 1);
# Line 1033 | Line 1032 | static int aliasPhotonScatter (OBJREC *mat, RAY *rayIn
1032     /* Replacement scattering routine */
1033     photonScatter [aliasRec.otype] (&aliasRec, rayIn);
1034  
1036 #if 0
1035     /* Avoid potential memory leak? */
1036     if (aliasRec.os != aliasPtr -> os) {
1037 <      if (aliasObj -> os)
1038 <         free_os(aliasObj);
1037 >      if (aliasPtr -> os)
1038 >         free_os(aliasPtr);
1039        aliasPtr -> os = aliasRec.os;
1040     }
1043 #endif
1041  
1042     return 0;
1043   }
# Line 1475 | Line 1472 | static int setbrdfunc(BRDFDAT *bd)
1472  
1473  
1474  
1475 < static int brtdFuncPhotonScatter (OBJREC *mat, RAY *rayIn)
1476 < /* Generate new photon ray for BRTDfunc material and recurse */
1475 > static int brdfPhotonScatter (OBJREC *mat, RAY *rayIn)
1476 > /* Generate new photon ray for BRTDfunc material and recurse. Only ideal
1477 >   reflection and transmission are sampled for the specular componentent. */
1478   {
1479     int      hitfront = 1, hastexture, i;
1480     BRDFDAT  nd;
# Line 1486 | Line 1484 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1484     MFUNC    *mf;
1485     FVECT    bnorm;
1486  
1487 +   /* Check argz */
1488     if (mat -> oargs.nsargs < 10 || mat -> oargs.nfargs < 9)
1489        objerror(mat, USER, "bad # arguments");
1490 +      
1491     nd.mp = mat;
1492     nd.pr = rayIn;
1493 <   /* Dummies */
1493 >   /* Dummiez */
1494     nd.rspec = nd.tspec = 1.0;
1495     nd.trans = 0.5;
1496  
1497 <   /* Diffuse reflectance */
1497 >   /* Diffuz reflektanz */
1498     if (rayIn -> rod > 0.0)
1499        setcolor(nd.rdiff, mat -> oargs.farg[0], mat -> oargs.farg [1],
1500                 mat -> oargs.farg [2]);
1501     else
1502        setcolor(nd.rdiff, mat-> oargs.farg [3], mat -> oargs.farg [4],
1503                 mat -> oargs.farg [5]);
1504 <   /* Diffuse transmittance */
1504 >   /* Diffuz tranzmittanz */
1505     setcolor(nd.tdiff, mat -> oargs.farg [6], mat -> oargs.farg [7],
1506              mat -> oargs.farg [8]);
1507  
1508 <   /* Get modifiers */
1508 >   /* Get modz */
1509     raytexture(rayIn, mat -> omod);
1510     hastexture = (DOT(rayIn -> pert, rayIn -> pert) > sqr(FTINY));
1511     if (hastexture) {
# Line 1518 | Line 1518 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1518     }
1519  
1520     if (rayIn -> rod < 0.0) {
1521 <      /* Orient perturbed values */
1521 >      /* Orient perturbed valuz */
1522        nd.pdot = -nd.pdot;
1523        for (i = 0; i < 3; i++) {
1524           nd.pnorm [i] = -nd.pnorm [i];
# Line 1528 | Line 1528 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1528        hitfront = 0;
1529     }
1530    
1531 <   /* Get pattern color, modify diffuse values */
1531 >   /* Get pattern kolour, modify diffuz valuz */
1532     copycolor(nd.mcolor, rayIn -> pcol);
1533     multcolor(nd.rdiff, nd.mcolor);
1534     multcolor(nd.tdiff, nd.mcolor);
1535  
1536 <   /* Load cal file, evaluate spec refl/trans vars */
1536 >   /* Load cal file, evaluate spekula refl/tranz varz */
1537     nd.dp = NULL;
1538     mf = getfunc(mat, 9, 0x3f, 0);
1539     setbrdfunc(&nd);
# Line 1545 | Line 1545 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1545     if (errno == EDOM || errno == ERANGE)
1546        objerror(mat, WARNING, "compute error");
1547     else {
1548 <      /* Set up probabilities */
1548 >      /* Set up probz */
1549        prDiff = colorAvg(nd.rdiff);
1550        ptDiff = colorAvg(nd.tdiff);
1551        prSpec = colorAvg(rspecCol);
# Line 1553 | Line 1553 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1553        albedo = prDiff + ptDiff + prSpec + ptSpec;
1554     }
1555  
1556 <   /* Insert direct and indirect photon hits if diffuse component */
1556 >   /* Insert direct and indirect photon hitz if diffuz komponent */
1557     if (prDiff > FTINY || ptDiff > FTINY)
1558        addPhotons(rayIn);
1559  
1560 <   /* Stochastically sample absorption or scattering events */
1560 >   /* Stochastically sample absorption or scattering evenz */
1561     if ((xi = pmapRandom(rouletteState)) > albedo)
1562        /* Absorbed */
1563        return 0;
1564  
1565     if (xi > (albedo -= prSpec)) {
1566 <      /* Specular reflection */
1566 >      /* Ideal spekula reflekzion */
1567        photonRay(rayIn, &rayOut, PMAP_SPECREFL, rspecCol);
1568        VSUM(rayOut.rdir, rayIn -> rdir, nd.pnorm, 2 * nd.pdot);
1569        checknorm(rayOut.rdir);
1570     }
1571     else if (xi > (albedo -= ptSpec)) {
1572 <      /* Specular transmission */
1572 >      /* Ideal spekula tranzmission */
1573        photonRay(rayIn, &rayOut, PMAP_SPECTRANS, tspecCol);
1574        if (hastexture) {
1575 <         /* Perturb direction */
1575 >         /* Perturb direkzion */
1576           VSUB(rayOut.rdir, rayIn -> rdir, rayIn -> pert);
1577           if (normalize(rayOut.rdir) == 0.0) {
1578              objerror(mat, WARNING, "illegal perturbation");
1579              VCOPY(rayOut.rdir, rayIn -> rdir);
1580           }
1581         else VCOPY(rayOut.rdir, rayIn -> rdir);
1581        }
1582 +      else VCOPY(rayOut.rdir, rayIn -> rdir);
1583     }
1584     else if (xi > (albedo -= prDiff)) {
1585 <      /* Diffuse reflection */
1585 >      /* Diffuz reflekzion */
1586        if (!hitfront)
1587           flipsurface(rayIn);
1588        photonRay(rayIn, &rayOut, PMAP_DIFFREFL, nd.mcolor);
1589        diffPhotonScatter(nd.pnorm, &rayOut);
1590     }
1591     else {
1592 <      /* Diffuse transmission */
1592 >      /* Diffuz tranzmission */
1593        if (hitfront)
1594           flipsurface(rayIn);
1595        photonRay(rayIn, &rayOut, PMAP_DIFFTRANS, nd.mcolor);
# Line 1599 | Line 1599 | static int brtdFuncPhotonScatter (OBJREC *mat, RAY *ra
1599        diffPhotonScatter(bnorm, &rayOut);
1600     }
1601  
1602 +   tracePhoton(&rayOut);
1603     return 0;
1604   }
1605  
1606  
1607  
1608 < #if 0
1609 < int
1610 < m_brdf2(                        /* color a ray that hit a BRDF material */
1610 <        OBJREC  *m,
1611 <        RAY  *r
1612 < )
1608 > int brdf2PhotonScatter (OBJREC *mat, RAY *rayIn)
1609 > /* Generate new photon ray for procedural or data driven BRDF material and
1610 >   recurse. Only diffuse reflection and transmission are sampled. */
1611   {
1612 <        BRDFDAT  nd;
1613 <        COLOR  ctmp;
1614 <        FVECT  vtmp;
1615 <        double  dtmp;
1616 <                                                /* always a shadow */
1619 <        if (r->crtype & SHADOW)
1620 <                return(1);
1621 <                                                /* check arguments */
1622 <        if ((m->oargs.nsargs < (hasdata(m->otype)?4:2)) | (m->oargs.nfargs <
1623 <                        ((m->otype==MAT_TFUNC)|(m->otype==MAT_TDATA)?6:4)))
1624 <                objerror(m, USER, "bad # arguments");
1625 <                                                /* check for back side */
1626 <        if (r->rod < 0.0) {
1627 <                if (!backvis) {
1628 <                        raytrans(r);
1629 <                        return(1);
1630 <                }
1631 <                raytexture(r, m->omod);
1632 <                flipsurface(r);                 /* reorient if backvis */
1633 <        } else
1634 <                raytexture(r, m->omod);
1612 >   BRDFDAT  nd;
1613 >   RAY      rayOut;
1614 >   double   dtmp, prDiff, ptDiff, albedo, xi;
1615 >   MFUNC    *mf;
1616 >   FVECT    bnorm;
1617  
1618 <        nd.mp = m;
1619 <        nd.pr = r;
1620 <                                                /* get material color */
1621 <        setcolor(nd.mcolor, m->oargs.farg[0],
1622 <                        m->oargs.farg[1],
1623 <                        m->oargs.farg[2]);
1624 <                                                /* get specular component */
1625 <        nd.rspec = m->oargs.farg[3];
1626 <                                                /* compute transmittance */
1627 <        if ((m->otype == MAT_TFUNC) | (m->otype == MAT_TDATA)) {
1628 <                nd.trans = m->oargs.farg[4]*(1.0 - nd.rspec);
1629 <                nd.tspec = nd.trans * m->oargs.farg[5];
1630 <                dtmp = nd.trans - nd.tspec;
1631 <                setcolor(nd.tdiff, dtmp, dtmp, dtmp);
1632 <        } else {
1633 <                nd.tspec = nd.trans = 0.0;
1634 <                setcolor(nd.tdiff, 0.0, 0.0, 0.0);
1635 <        }
1654 <                                                /* compute reflectance */
1655 <        dtmp = 1.0 - nd.trans - nd.rspec;
1656 <        setcolor(nd.rdiff, dtmp, dtmp, dtmp);
1657 <        nd.pdot = raynormal(nd.pnorm, r);       /* perturb normal */
1658 <        multcolor(nd.mcolor, r->pcol);          /* modify material color */
1659 <        multcolor(nd.rdiff, nd.mcolor);
1660 <        multcolor(nd.tdiff, nd.mcolor);
1661 <                                                /* load auxiliary files */
1662 <        if (hasdata(m->otype)) {
1663 <                nd.dp = getdata(m->oargs.sarg[1]);
1664 <                getfunc(m, 2, 0, 0);
1665 <        } else {
1666 <                nd.dp = NULL;
1667 <                getfunc(m, 1, 0, 0);
1668 <        }
1669 <                                                /* compute ambient */
1670 <        if (nd.trans < 1.0-FTINY) {
1671 <                copycolor(ctmp, nd.mcolor);     /* modified by material color */
1672 <                scalecolor(ctmp, 1.0-nd.trans);
1673 <                multambient(ctmp, r, nd.pnorm);
1674 <                addcolor(r->rcol, ctmp);        /* add to returned color */
1675 <        }
1676 <        if (nd.trans > FTINY) {         /* from other side */
1677 <                flipsurface(r);
1678 <                vtmp[0] = -nd.pnorm[0];
1679 <                vtmp[1] = -nd.pnorm[1];
1680 <                vtmp[2] = -nd.pnorm[2];
1681 <                copycolor(ctmp, nd.mcolor);
1682 <                scalecolor(ctmp, nd.trans);
1683 <                multambient(ctmp, r, vtmp);
1684 <                addcolor(r->rcol, ctmp);
1685 <                flipsurface(r);
1686 <        }
1687 <                                                /* add direct component */
1688 <        direct(r, dirbrdf, &nd);
1618 >   /* Check argz */
1619 >   if (mat -> oargs.nsargs < (hasdata(mat -> otype) ? 4 : 2) ||
1620 >       mat -> oargs.nfargs < (mat -> otype == MAT_TFUNC ||
1621 >                              mat -> otype == MAT_TDATA ? 6 : 4))
1622 >      objerror(mat, USER, "bad # arguments");
1623 >      
1624 >   if (rayIn -> rod < 0.0) {
1625 >      /* Hit backside; reorient if visible, else transfer photon */
1626 >      if (!backvis) {
1627 >         photonRay(rayIn, &rayOut, PMAP_XFER, NULL);
1628 >         tracePhoton(&rayOut);
1629 >         return 0;
1630 >      }
1631 >      
1632 >      raytexture(rayIn, mat -> omod);
1633 >      flipsurface(rayIn);
1634 >   }
1635 >   else raytexture(rayIn, mat -> omod);
1636  
1637 <        return(1);
1637 >   nd.mp = mat;
1638 >   nd.pr = rayIn;
1639 >  
1640 >   /* Material kolour */
1641 >   setcolor(nd.mcolor, mat -> oargs.farg [0], mat -> oargs.farg [1],
1642 >            mat -> oargs.farg [2]);
1643 >   /* Spekula komponent */
1644 >   nd.rspec = mat -> oargs.farg [3];
1645 >  
1646 >   /* Tranzmittanz */
1647 >   if (mat -> otype == MAT_TFUNC || mat -> otype == MAT_TDATA) {
1648 >      nd.trans = mat -> oargs.farg [4] * (1.0 - nd.rspec);
1649 >      nd.tspec = nd.trans * mat -> oargs.farg [5];
1650 >      dtmp = nd.trans - nd.tspec;
1651 >      setcolor(nd.tdiff, dtmp, dtmp, dtmp);
1652 >   }
1653 >   else {
1654 >      nd.tspec = nd.trans = 0.0;
1655 >      setcolor(nd.tdiff, 0.0, 0.0, 0.0);
1656 >   }
1657 >  
1658 >   /* Reflektanz */
1659 >   dtmp = 1.0 - nd.trans - nd.rspec;
1660 >   setcolor(nd.rdiff, dtmp, dtmp, dtmp);
1661 >   /* Perturb normal */
1662 >   nd.pdot = raynormal(nd.pnorm, rayIn);
1663 >   /* Modify material kolour */
1664 >   multcolor(nd.mcolor, rayIn -> pcol);
1665 >   multcolor(nd.rdiff, nd.mcolor);
1666 >   multcolor(nd.tdiff, nd.mcolor);
1667 >  
1668 >   /* Load auxiliary filez */
1669 >   if (hasdata(mat -> otype)) {
1670 >      nd.dp = getdata(mat -> oargs.sarg [1]);
1671 >      getfunc(mat, 2, 0, 0);
1672 >   }
1673 >   else {
1674 >      nd.dp = NULL;
1675 >      getfunc(mat, 1, 0, 0);
1676 >   }
1677 >
1678 >   /* Set up probz */
1679 >   prDiff = colorAvg(nd.rdiff);
1680 >   ptDiff = colorAvg(nd.tdiff);
1681 >   albedo = prDiff + ptDiff;
1682 >
1683 >   /* Insert direct and indirect photon hitz if diffuz komponent */
1684 >   if (prDiff > FTINY || ptDiff > FTINY)
1685 >      addPhotons(rayIn);
1686 >
1687 >   /* Stochastically sample absorption or scattering evenz */
1688 >   if ((xi = pmapRandom(rouletteState)) > albedo)
1689 >      /* Absorbed */
1690 >      return 0;
1691 >
1692 >   if (xi > (albedo -= prDiff)) {
1693 >      /* Diffuz reflekzion */
1694 >      photonRay(rayIn, &rayOut, PMAP_DIFFREFL, nd.rdiff);
1695 >      diffPhotonScatter(nd.pnorm, &rayOut);
1696 >   }
1697 >   else {
1698 >      /* Diffuz tranzmission */
1699 >      flipsurface(rayIn);
1700 >      photonRay(rayIn, &rayOut, PMAP_DIFFTRANS, nd.tdiff);
1701 >      bnorm [0] = -nd.pnorm [0];
1702 >      bnorm [1] = -nd.pnorm [1];
1703 >      bnorm [2] = -nd.pnorm [2];
1704 >      diffPhotonScatter(bnorm, &rayOut);
1705 >   }
1706 >
1707 >   tracePhoton(&rayOut);
1708 >   return 0;
1709   }
1692 #endif
1710  
1711  
1712  
# Line 1953 | Line 1970 | void initPhotonScatterFuncs ()
1970   /* Init photonScatter[] dispatch table */
1971   {
1972     int i;
1973 <  
1973 >
1974     /* Catch-all for inconsistencies */
1975     for (i = 0; i < NUMOTYPE; i++)
1976        photonScatter [i] = o_default;
1977 <      
1977 >
1978     photonScatter [MAT_LIGHT] = photonScatter [MAT_ILLUM] =
1979        photonScatter [MAT_GLOW] = photonScatter [MAT_SPOT] =
1980           lightPhotonScatter;
1981 <        
1981 >
1982     photonScatter [MAT_PLASTIC] = photonScatter [MAT_METAL] =
1983        photonScatter [MAT_TRANS] = normalPhotonScatter;
1984        
# Line 1970 | Line 1987 | void initPhotonScatterFuncs ()
1987        
1988     photonScatter [MAT_DIELECTRIC] = photonScatter [MAT_INTERFACE] =
1989        dielectricPhotonScatter;
1990 <      
1990 >
1991     photonScatter [MAT_MIST] = mistPhotonScatter;
1992     photonScatter [MAT_GLASS] = glassPhotonScatter;
1993     photonScatter [MAT_CLIP] = clipPhotonScatter;
# Line 1978 | Line 1995 | void initPhotonScatterFuncs ()
1995     photonScatter [MIX_FUNC] = mx_funcPhotonScatter;
1996     photonScatter [MIX_DATA] = mx_dataPhotonScatter;
1997     photonScatter [MIX_PICT]= mx_pdataPhotonScatter;
1998 <  
1998 >
1999     photonScatter [PAT_BDATA] = photonScatter [PAT_CDATA] =
2000        photonScatter [PAT_BFUNC] = photonScatter [PAT_CFUNC] =
2001           photonScatter [PAT_CPICT] = photonScatter [TEX_FUNC] =
2002              photonScatter [TEX_DATA] = pattexPhotonScatter;
2003 <            
2003 >
2004     photonScatter [MOD_ALIAS] = aliasPhotonScatter;
2005 <   photonScatter [MAT_BRTDF] = brtdFuncPhotonScatter;
2006 <   photonScatter [MAT_BSDF] =
2007 <      photonScatter [MAT_ABSDF] = bsdfPhotonScatter;
2005 >   photonScatter [MAT_BRTDF] = brdfPhotonScatter;
2006 >  
2007 >   photonScatter [MAT_PFUNC] = photonScatter [MAT_MFUNC] =
2008 >      photonScatter [MAT_PDATA] = photonScatter [MAT_MDATA] =
2009 >         photonScatter [MAT_TFUNC] = photonScatter [MAT_TDATA] =
2010 >            brdf2PhotonScatter;
2011 >
2012 >   photonScatter [MAT_BSDF] = photonScatter [MAT_ABSDF] =
2013 >      bsdfPhotonScatter;
2014   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines