source: trunk/VUT/GtpVisibilityPreprocessor/src/X3dExporter.h @ 396

Revision 396, 2.1 KB checked in by mattausch, 19 years ago (diff)

fixed bug in bsp geometry construction

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"
[162]13
14class SceneGraphNode;
15class Mesh;
[176]16class Intersectable;
17class MeshInstance;
[242]18class Polygon3;
19class ViewCell;
20class BspTree;
[162]21
22class X3dExporter : public Exporter
23{
24  std::ofstream stream;
25
26public:
27
28  X3dExporter(const string filename);
29
30  ~X3dExporter();
31
32
[386]33//    bool
34//    ExportRays(const vector<Ray> &rays,
35//           const float length=1000,
36//           const RgbColor &color = RgbColor(1,1,1));
[162]37
38  bool
39  ExportKdTree(const KdTree &tree);
40 
[242]41  bool ExportBspTree(const BspTree &tree);
42
[162]43  bool
44  ExportScene(SceneGraphNode *root)
45  {
46    ExportSceneNode(root);
47    return true;
48  }
49 
[242]50  virtual void
[260]51  ExportPolygon(Polygon3 *poly);
[242]52
[362]53  virtual void
54  ExportPolygons(const PolygonContainer &polys);
[263]55
[176]56  virtual bool
[162]57  ExportBox(const AxisAlignedBox3 &box);
58
59  virtual void
60  ExportMeshInstance(MeshInstance *mi);
61
[176]62  virtual void
63  ExportIntersectable(Intersectable *object);
64
65  virtual void
[162]66  ExportMesh(Mesh *mesh);
67
[260]68  virtual void
69  ExportViewCell(ViewCell *viewCell);
[176]70
[261]71  virtual void
[313]72  ExportViewCells(const ViewCellContainer &viewCells);
[312]73
[313]74  virtual void
75  ExportBspSplitPlanes(const BspTree &tree);
76 
77  virtual void
[383]78  ExportBspSplits(const BspTree &tree, const bool exportDepth);
[312]79
[360]80  virtual void
81  ExportLeavesGeometry(const BspTree &tree, const vector<BspLeaf *> &leaves);
82
[349]83  bool
84  ExportRays(const RayContainer &rays,
[386]85                                                 const float length=1000,
86                                                 const RgbColor &color = RgbColor(1,1,1));
[349]87
[386]88        bool
89        ExportRays(const VssRayContainer &rays,
90                                                 const RgbColor &color = RgbColor(1,1,1));
91               
[373]92  virtual void
[379]93  ExportBspViewCellPartition(const BspTree &tree, const int maxPvs = 0);
[373]94
95  virtual void
[396]96  ExportBspLeaves(const BspTree &tree, const int maxPvs = 0);
[373]97
[162]98protected:
[329]99
[176]100  virtual void
[162]101  ExportSceneNode(SceneGraphNode *node);
102
[191]103  bool
104  ExportKdTreeRayDensity(const KdTree &tree);
105
[263]106  bool
107  ExportBspTreeRayDensity(const BspTree &tree); 
[162]108};
109 
110
111
112#endif
Note: See TracBrowser for help on using the repository browser.