--- ray/src/rt/pmapray.c 2016/05/17 17:39:47 2.6 +++ ray/src/rt/pmapray.c 2016/11/02 22:09:14 2.7 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: pmapray.c,v 2.6 2016/05/17 17:39:47 rschregle Exp $"; +static const char RCSid[] = "$Id: pmapray.c,v 2.7 2016/11/02 22:09:14 greg Exp $"; #endif /* @@ -12,7 +12,7 @@ static const char RCSid[] = "$Id: pmapray.c,v 2.6 2016 supported by the Swiss National Science Foundation (SNSF, #147053) ================================================================== - $Id: pmapray.c,v 2.6 2016/05/17 17:39:47 rschregle Exp $ + $Id: pmapray.c,v 2.7 2016/11/02 22:09:14 greg Exp $ */ @@ -47,6 +47,7 @@ void ray_save_pmap (RAYPARAMS *rp) rp -> pmapParams [t].minGather = pmapParams [t].minGather; rp -> pmapParams [t].maxGather = pmapParams [t].maxGather; + rp -> pmapParams [t].distribTarget = pmapParams [t].distribTarget; } } @@ -60,5 +61,19 @@ void ray_restore_pmap (RAYPARAMS *rp) pmapParams [t].fileName = rp -> pmapParams [t].fileName; pmapParams [t].minGather = rp -> pmapParams [t].minGather; pmapParams [t].maxGather = rp -> pmapParams [t].maxGather; + pmapParams [t].distribTarget = rp -> pmapParams [t].distribTarget; + } +} + +void ray_defaults_pmap (RAYPARAMS *rp) +/* Interface to ray_defaults(); set photon mapping defaults */ +{ + unsigned t; + + for (t = 0; t < NUM_PMAP_TYPES; t++) { + rp -> pmapParams [t].fileName = NULL; + rp -> pmapParams [t].minGather = 0; + rp -> pmapParams [t].maxGather = 0; + rp -> pmapParams [t].distribTarget = 0; } }