basic/geometry/vrml_reader/VrmlIndexedFaceSet.h

Go to the documentation of this file.
00001 #ifndef _VRMLINDEXEDFACESET_H_
00002 #define _VRMLINDEXEDFACESET_H_
00003 
00004 #include "keyword.h"
00005 #include <vector>
00006 #include "VrmlNode.h"
00007 
00008 class VrmlIndexedFaceSet : public VrmlNode
00009 {
00010 public:
00011         //data
00012 //      std::vector< Vector4 > points;
00013 
00014         //methods
00015         Keyword GetKeyword( char*& buffer );
00016         virtual void Parse( char*& buffer );
00017         virtual void Render( VrmlStack& stack ) const;
00018         virtual void RenderOpenGl( VrmlStack& stack ) const;
00019         virtual IGS_Object* RenderToIGS( VrmlStack& stack ) const;
00020         VrmlIndexedFaceSet();
00021         virtual ~VrmlIndexedFaceSet();
00022 
00023 protected:
00024         void ComputeNormals( VrmlStack& stack ) const;
00025         Vector4 GetNormal( const int index, VrmlStack& stack ) const;
00026     void ParseNodeColor( char*& buffer );
00027     void ParseNodeCoord( char*& buffer );
00028         void ParseNodeCoordIndex( char*& buffer );
00029         void ParseNodeIgnore( char*& buffer );
00030         void ParseNodeMaterialIndex( char*& buffer );
00031         void ParseNodeNormalIndex( char*& buffer );
00032         void ParseNodeTexCoord( char*& buffer );
00033         virtual void ParseSubnode( Keyword keyword, char*& buffer );
00034 
00035         std::vector< int > indexes;             //IAN IMPROVE: vector is not a good choice
00036         mutable std::vector< Vector4 > m_Normals;
00037         VrmlNode* m_Coords;
00038         mutable bool m_NormalsComputed;
00039         VrmlNode* m_TexCoord;
00040 };
00041 
00042 #endif

Generated on Sat Apr 1 21:30:34 2006 for Motion Planning Kernel by  doxygen 1.4.6-NO