Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

MESH_MeshFacesDrawer.h

Go to the documentation of this file.
00001 
00002 //                             MESH_MeshFacesDrawer.h                         //
00004 
00005 #ifndef MESH_FACESDRAWER_H
00006 #define MESH_FACESDRAWER_H
00007 
00008 #include "MESH_MeshFacesDrawerStateVariables.h"
00009 #include "X3DOnePassProcessor.h"
00010 #include "MESH_SceneGraphTypes.h"
00011 #include "MESH_DFSGraphTraversal.h"
00012 #include "MESH_MeshFacesDrawerCoreVisitor.h"
00013 #include "MESH_Mesh.h"
00014 
00015 namespace X3DTK {
00016 namespace MESH {
00017 
00018 // Processor drawing the mesh from the Mesh scene graph.
00019 
00020 template<class MData, class VData, class EData, class FData>
00021 class MeshFacesDrawer : public X3DOnePassProcessor
00022 {
00023 public:
00025   MeshFacesDrawer();
00027   virtual ~MeshFacesDrawer();
00028   
00030   void changeOneColorPerMesh();
00031   
00033   void draw(X3DNode *N, bool selection = false);
00034   
00035   // Get ith Mesh of the scene.
00036   inline Mesh<MData, VData, EData, FData> *getMesh(int i) const;
00037   // Gets stored transformation matrix associated with a given Mesh.
00038   inline const SFMatrix34f &getMatrix(int i) const;
00040   inline typename Mesh<MData, VData, EData, FData>::SFFace *getFaceOfMesh(int i, int j) const;
00041   
00042 protected:
00043   MeshFacesDrawerStateVariables<MData, VData, EData, FData>* stateVariables;
00044 };
00045 
00046 }
00047 }
00048 
00049 #include "MESH_MeshFacesDrawer.inl"
00050 
00051 #endif
00052 

Generated on Mon Jan 19 10:32:04 2004 for X3DToolKit by doxygen1.2.18