| 1 |
+ |
/* RCSid $Id$ */ |
| 2 |
+ |
|
| 3 |
|
/* |
| 4 |
< |
================================================================== |
| 4 |
> |
====================================================================== |
| 5 |
|
Photon map file I/O |
| 6 |
|
|
| 7 |
|
Roland Schregle (roland.schregle@{hslu.ch, gmail.com}) |
| 8 |
|
(c) Fraunhofer Institute for Solar Energy Systems, |
| 9 |
|
(c) Lucerne University of Applied Sciences and Arts, |
| 10 |
< |
supported by the Swiss National Science Foundation (SNSF, #147053) |
| 11 |
< |
================================================================== |
| 10 |
> |
supported by the Swiss National Science Foundation (SNSF, #147053) |
| 11 |
> |
====================================================================== |
| 12 |
|
|
| 13 |
|
$Id$ |
| 14 |
|
*/ |
| 18 |
|
#define PMAPIO_H |
| 19 |
|
|
| 20 |
|
#include "pmapdata.h" |
| 21 |
+ |
|
| 22 |
+ |
|
| 23 |
+ |
/* File format version with feature suffix */ |
| 24 |
+ |
#define PMAP_FILEVER_MAJ "3.0" |
| 25 |
|
|
| 26 |
< |
#define PMAP_FILEVER 160u /* File format version */ |
| 26 |
> |
#ifdef PMAP_OOC |
| 27 |
> |
#define PMAP_FILEVER_TYP "o" |
| 28 |
> |
#else |
| 29 |
> |
#define PMAP_FILEVER_TYP "k" |
| 30 |
> |
#endif |
| 31 |
> |
|
| 32 |
> |
#ifdef PMAP_FLOAT_FLUX |
| 33 |
> |
#define PMAP_FILEVER_FLX "f" |
| 34 |
> |
#else |
| 35 |
> |
#define PMAP_FILEVER_FLX "" |
| 36 |
> |
#endif |
| 37 |
> |
|
| 38 |
> |
#ifdef PMAP_PRIMARYPOS |
| 39 |
> |
#define PMAP_FILEVER_PRI "p" |
| 40 |
> |
#else |
| 41 |
> |
#define PMAP_FILEVER_PRI "" |
| 42 |
> |
#endif |
| 43 |
|
|
| 44 |
+ |
#define PMAP_FILEVER (PMAP_FILEVER_MAJ PMAP_FILEVER_TYP \ |
| 45 |
+ |
PMAP_FILEVER_FLX PMAP_FILEVER_PRI) |
| 46 |
+ |
|
| 47 |
+ |
|
| 48 |
|
void savePhotonMap (const PhotonMap *pmap, const char *fname, |
| 49 |
< |
PhotonMapType type, int argc, char **argv); |
| 49 |
> |
int argc, char **argv); |
| 50 |
|
/* Save portable photon map of specified type to filename, |
| 51 |
|
along with the corresponding command line. */ |
| 52 |
|
|