source: trunk/VUT/GtpVisibilityPreprocessor/src/Exporter.h @ 191

Revision 191, 1.4 KB checked in by bittner, 19 years ago (diff)

basic sampling strategies

RevLine 
[162]1#ifndef __EXPORTER_H
2#define __EXPORTER_H
3
4#include <string>
5#include <vector>
6using namespace std;
7
[176]8#include "Material.h"
9
[162]10class KdTree;
11class SceneGraphNode;
12class Ray;
13class AxisAlignedBox3;
[176]14class Intersectable;
[162]15
16class Exporter
17{
18protected:
19  string mFilename;
[191]20  bool mWireframe;
[176]21  bool mUseForcedMaterial;
22  Material mForcedMaterial;
[162]23
[191]24  bool mExportRayDensity;
25 
[162]26public:
27 
[176]28  Exporter(const string filename):mFilename(filename),
[191]29                                  mWireframe(false),
30                                  mUseForcedMaterial(false),
31                                  mExportRayDensity(false)
[162]32  {
33  }
[170]34  virtual ~Exporter() {}
[162]35 
36  virtual bool ExportScene(SceneGraphNode *node) = 0;
37
38  virtual bool
39  ExportBox(const AxisAlignedBox3 &box) = 0;
40
41  virtual bool
42  ExportKdTree(const KdTree &tree) = 0;
43
44  virtual bool
[176]45  ExportRays(const vector<Ray> &rays,
46             const float length=1000,
47             const RgbColor &color = RgbColor(1,1,1)
48             ) = 0;
49 
[162]50
51  virtual void
[176]52  ExportIntersectable(Intersectable *object) = 0;
53
[191]54  void SetExportRayDensity(const bool d) { mExportRayDensity = d; }
55 
56  void SetWireframe() { mWireframe = true; }
57  void SetFilled() { mWireframe = false; }
[162]58
[176]59  void SetForcedMaterial(const Material &m) {
60    mForcedMaterial = m;
61    mUseForcedMaterial = true;
62  }
63  void ResetForcedMaterial() {
64    mUseForcedMaterial = false;
65  }
66   
[162]67  static Exporter *
68  GetExporter(const string filename);
69
[170]70 
[162]71};
72 
73
74
75#endif
Note: See TracBrowser for help on using the repository browser.