00001 00002 // TemplateMeshBuilderGlobalVariables.h // 00004 00005 #ifndef TEMPLATEMESHBUILDERGLOBALVARIABLES_H 00006 #define TEMPLATEMESHBUILDERGLOBALVARIABLES_H 00007 00008 #include "GlobalVariables.h" 00009 #include "MESH_X3DNode.h" 00010 00011 namespace X3DTK { 00012 namespace X3D { 00013 00015 00016 class TemplateMeshBuilderGlobalVariables : public GlobalVariables 00017 { 00018 public: 00020 TemplateMeshBuilderGlobalVariables(); 00022 virtual ~TemplateMeshBuilderGlobalVariables(); 00024 void init(); 00026 virtual void finish(); 00027 00029 void pushNode(MESH::SFNode N); 00031 void popNode(); 00032 00034 inline MESH::SFNode getRoot() const {return _root;}; 00036 inline MESH::SFNode getTop() const {return _nodeStack.front();}; 00037 00038 private: 00039 MESH::SFNode _root; 00040 MESH::MFNode _nodeStack; 00041 }; 00042 00043 } 00044 } 00045 00046 #endif