--- ray/src/rt/pmapdata.h 2015/05/08 13:20:22 2.2 +++ ray/src/rt/pmapdata.h 2015/09/01 16:27:52 2.9 @@ -1,3 +1,4 @@ +/* RCSid $Id: pmapdata.h,v 2.9 2015/09/01 16:27:52 greg Exp $ */ /* ================================================================== Photon map data structures and kd-tree handling @@ -8,7 +9,6 @@ supported by the Swiss National Science Foundation (SNSF, #147053) ================================================================== - $Id: pmapdata.h,v 2.2 2015/05/08 13:20:22 rschregle Exp $ */ @@ -34,8 +34,9 @@ /* Primary photon ray for light source contributions */ typedef struct { - short srcIdx; /* Index of emitting light source */ - float dir [3], org [3]; /* Incident dir & origin on source */ + int32 srcIdx; /* Index of emitting light source */ + int32 dir; /* Encoded ray direction */ + float pos [3]; /* Hit point */ } PhotonPrimary; #define photonSrcIdx(pm, p) ((pm) -> primary [(p) -> primary].srcIdx) @@ -53,7 +54,7 @@ COLR flux; /* Photon flux */ #endif - unsigned primary; /* Index to primary ray */ + uint32 primary; /* Index to primary ray */ } Photon; /* Photon flag bitmasks and manipulation macros */