/* ====================================================================== In-core kd-tree for 4D TRANSIENT photon map. Based on pmapkdt.h with extensions to handle photon path length (representing time of flight). Roland Schregle (roland.schregle@{hslu.ch, gmail.com}) (c) Tokyo University of Science, supported by the JSPS Grants-in-Aid for Scientific Research (KAKENHI JP19KK0115, "Three-Dimensional Light Flow") ====================================================================== $Id$ */ #ifndef PMAPTKDT_H #define PMAPTKDT_H #include "pmapkdt.h" int kdT_TransFindPhotons (struct PhotonMap* pmap, const FVECT pos, const FVECT norm ); /* Locate pmap -> squeue.len nearest photons to pos with similar normal * (ignored if NULL) at time pmap->time for speed of light pmap->velocity. * Return nearest photons in search queue pmap->squeue, starting with the * furthest photon at pmap -> squeue.node. * Return value = -1 if none found, else 0. */ int kdT_TransFind1Photon (struct PhotonMap* pmap, const FVECT pos, const FVECT norm, Photon *photon ); /* Locate single nearest photon to pos with similar normal at time * pmap->time for speed of light pmap->velocity. * Return value = -1 if none found, else 0. */ #endif