source: GTP/trunk/Lib/Vis/Preprocessing/src/X3dExporter.h @ 863

Revision 863, 2.9 KB checked in by mattausch, 18 years ago (diff)

working on preprocessor integration
added iv stuff

RevLine 
[162]1#ifndef __X3DEXPORTER_H
2#define __X3DEXPORTER_H
3
4#include <string>
5using std::string;
6
7#include <iostream>
8#include <fstream>
9
10#include "Exporter.h"
[261]11#include "Containers.h"
[386]12#include "VssRay.h"
[469]13#include "ViewCell.h"
[162]14
[860]15namespace GtpVisibilityPreprocessor {
16
[162]17class SceneGraphNode;
18class Mesh;
[176]19class Intersectable;
20class MeshInstance;
[242]21class Polygon3;
22class ViewCell;
23class BspTree;
[448]24class VspBspTree;
25class BspNode;
[469]26//class VspKdViewCell;
[535]27class Beam;
[162]28
29class X3dExporter : public Exporter
30{
31  std::ofstream stream;
32
33public:
34
35  X3dExporter(const string filename);
36
37  ~X3dExporter();
38
39
[386]40//    bool
41//    ExportRays(const vector<Ray> &rays,
42//           const float length=1000,
43//           const RgbColor &color = RgbColor(1,1,1));
[162]44
[446]45
[162]46  bool
47  ExportKdTree(const KdTree &tree);
[434]48
[438]49  bool
[434]50  ExportVssTree(const VssTree &tree);
51
[438]52  bool
53  ExportVssTree2(const VssTree &tree,
54                                 const Vector3 direction
55                                 );
[446]56
57  virtual bool
58  ExportRssTree2(const RssTree &tree,
59                                 const Vector3 direction
60                                 );
61
[462]62  bool
[425]63  ExportVspKdTree(const VspKdTree &tree, const int maxPvs);
[418]64
[242]65  bool ExportBspTree(const BspTree &tree);
66
[162]67  bool
[462]68  ExportScene(SceneGraphNode *root)
[162]69  {
70    ExportSceneNode(root);
71    return true;
72  }
[462]73
74  virtual void
[260]75  ExportPolygon(Polygon3 *poly);
[242]76
[462]77  virtual void
[362]78  ExportPolygons(const PolygonContainer &polys);
[263]79
[176]80  virtual bool
[162]81  ExportBox(const AxisAlignedBox3 &box);
82
83  virtual void
84  ExportMeshInstance(MeshInstance *mi);
85
[176]86  virtual void
87  ExportIntersectable(Intersectable *object);
88
89  virtual void
[162]90  ExportMesh(Mesh *mesh);
91
[462]92  virtual void
[260]93  ExportViewCell(ViewCell *viewCell);
[176]94
[462]95  virtual void
[313]96  ExportViewCells(const ViewCellContainer &viewCells);
[312]97
[462]98  virtual void
[440]99  ExportGeometry(const ObjectContainer &objects);
100
[448]101  bool
102  ExportRays(const RayContainer &rays,
103                         const float length=1000,
104                         const RgbColor &color = RgbColor(1,1,1));
105  bool
106  ExportRays(const VssRayContainer &rays,
107                         const RgbColor &color = RgbColor(1,1,1));
108
[462]109  virtual void
[313]110  ExportBspSplitPlanes(const BspTree &tree);
[462]111
112  virtual void
[383]113  ExportBspSplits(const BspTree &tree, const bool exportDepth);
[312]114
[360]115  virtual void
116  ExportLeavesGeometry(const BspTree &tree, const vector<BspLeaf *> &leaves);
117
[373]118  virtual void
[396]119  ExportBspLeaves(const BspTree &tree, const int maxPvs = 0);
[373]120
[448]121
[462]122  virtual void
[448]123  ExportBspSplits(const VspBspTree &tree, const bool exportDepth);
124
[535]125  virtual void ExportBeam(const Beam &beam, const AxisAlignedBox3 &box);
126
[162]127protected:
[329]128
[448]129
[176]130  virtual void
[162]131  ExportSceneNode(SceneGraphNode *node);
132
[191]133  bool
134  ExportKdTreeRayDensity(const KdTree &tree);
135
[263]136  bool
[434]137  ExportBspTreeRayDensity(const BspTree &tree);
[462]138
[448]139  void ExportBspNodeSplits(BspNode *root,
[462]140                                                   const AxisAlignedBox3 &box,
[448]141                                                   const bool exportDepth,
[462]142                                                   const bool epsilon);
[459]143
144
145  void ExportViewpoint(const Vector3 &point, const Vector3 &direction);
146
[162]147};
148
[863]149};
[162]150
151#endif
Note: See TracBrowser for help on using the repository browser.