ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/pmapparm.h
Revision: 2.9
Committed: Fri Feb 2 19:47:55 2018 UTC (6 years, 3 months ago) by rschregle
Content type: text/plain
Branch: MAIN
CVS Tags: rad5R2, rad5R3
Changes since 2.8: +4 -3 lines
Log Message:
Added -lr, -ld options to mkpmap, enabled -api

File Contents

# User Rev Content
1 rschregle 2.9 /* RCSid $Id: pmapparm.h,v 2.8 2017/08/14 21:12:10 rschregle Exp $ */
2 rschregle 2.7
3 greg 2.1 /*
4 rschregle 2.7 ======================================================================
5     Parameters for photon map generation and rendering; used by mkpmap
6     and rpict/rvu/rtrace.
7 greg 2.1
8     Roland Schregle (roland.schregle@{hslu.ch, gmail.com}
9     (c) Fraunhofer Institute for Solar Energy Systems,
10 rschregle 2.2 (c) Lucerne University of Applied Sciences and Arts,
11 rschregle 2.7 supported by the Swiss National Science Foundation (SNSF, #147053)
12     ======================================================================
13    
14 rschregle 2.9 $Id: pmapparm.h,v 2.8 2017/08/14 21:12:10 rschregle Exp $
15 greg 2.1 */
16    
17    
18     #ifndef PMAPPARAMS_H
19     #define PMAPPARAMS_H
20    
21     #include "pmaptype.h"
22    
23    
24     /* Struct for passing params per photon map from rpict/rtrace/rvu */
25     typedef struct {
26     char *fileName; /* Photon map file */
27     unsigned minGather, maxGather; /* Num photons to gather */
28     unsigned long distribTarget; /* Num photons to store */
29     } PhotonMapParams;
30 rschregle 2.8
31     /* Bounding box for region of interest */
32     typedef struct {
33     float min [3], max [3];
34     } PhotonMapROI;
35 greg 2.1
36    
37     extern PhotonMapParams pmapParams [NUM_PMAP_TYPES];
38    
39     /* Macros for type specific photon map parameters */
40     #define globalPmapParams (pmapParams [PMAP_TYPE_GLOBAL])
41     #define preCompPmapParams (pmapParams [PMAP_TYPE_PRECOMP])
42     #define causticPmapParams (pmapParams [PMAP_TYPE_CAUSTIC])
43     #define volumePmapParams (pmapParams [PMAP_TYPE_VOLUME])
44     #define directPmapParams (pmapParams [PMAP_TYPE_DIRECT])
45     #define contribPmapParams (pmapParams [PMAP_TYPE_CONTRIB])
46    
47    
48 rschregle 2.7 extern float pdfSamples, preDistrib, finalGather,
49 rschregle 2.9 gatherTolerance, maxDistFix, pmapMaxDist,
50     photonMaxDist;
51 rschregle 2.7 extern unsigned long photonHeapSizeInc, photonMaxBounce;
52 rschregle 2.8 extern unsigned photonRepTime, maxPreDistrib, defaultGather,
53     verbose;
54    
55     extern unsigned pmapNumROI;
56     extern PhotonMapROI *pmapROI;
57 greg 2.1
58 rschregle 2.7 #ifdef PMAP_OOC
59     extern float pmapCachePageSize;
60     extern unsigned long pmapCacheSize;
61     #endif
62    
63    
64 greg 2.1 struct PhotonMap;
65    
66     int setPmapParam (struct PhotonMap **pm, const PhotonMapParams *parm);
67     /* Allocate photon map and set its parameters from parm */
68    
69     unsigned long parseMultiplier (const char *num);
70     /* Evaluate numeric parameter string with optional multiplier suffix
71     (G = 10^9, M = 10^6, K = 10^3). Returns 0 if parsing fails. */
72     #endif