00001 ////////////////////////////////////////////////////////////////////// 00002 // Copyright (c) 2002-2003 David Pritchard <drpritch@alumni.uwaterloo.ca> 00003 // 00004 // This program is free software; you can redistribute it and/or 00005 // modify it under the terms of the GNU Lesser General Public License 00006 // as published by the Free Software Foundation; either 00007 // version 2 of the License, or (at your option) any later 00008 // version. 00009 // 00010 // This program is distributed in the hope that it will be useful, 00011 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 // GNU Lesser General Public License for more details. 00014 // 00015 // You should have received a copy of the GNU Lesser General Public License 00016 // along with this program; if not, write to the Free Software 00017 // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00018 00019 #ifndef freecloth_geom_geMeshTypes_h 00020 #define freecloth_geom_geMeshTypes_h 00021 00022 #ifndef freecloth_base_vector 00023 #include <freecloth/base/vector> 00024 #endif 00025 00026 #ifndef freecloth_geom_package_h 00027 #include <freecloth/geom/package.h> 00028 #endif 00029 00030 FREECLOTH_NAMESPACE_START 00031 00032 //////////////////////////////////////////////////////////////////////////////// 00033 // FORWARD DECLARATIONS 00034 // 00035 class GePoint; 00036 00037 //////////////////////////////////////////////////////////////////////////////// 00038 /*! 00039 * \class GeMeshTypes freecloth/geom/geMeshTypes.h 00040 * \brief A class to collect a few common typedefs. 00041 * 00042 * These typedefs are used by the various GeMesh* classes. 00043 */ 00044 class GeMeshTypes { 00045 00046 public: 00047 00048 // ----- types and enumerations ----- 00049 00050 //! Face index 00051 typedef UInt32 FaceId; 00052 //! Vertex index 00053 typedef UInt32 VertexId; 00054 //! Texture vertex index 00055 typedef UInt32 TextureVertexId; 00056 //! Index of a vertex within a face 00057 typedef UInt32 FaceVertexId; 00058 00059 //! Vertex 00060 typedef GePoint VertexType; 00061 //! Texture vertex, i.e. texture co-ordinates. 00062 typedef GePoint TextureVertexType; 00063 00064 //! Container for vertices 00065 typedef std::vector<VertexType> VertexContainer; 00066 //! Iterator for vertices 00067 typedef VertexContainer::iterator VertexIterator; 00068 //! ConstIterator for vertices 00069 typedef VertexContainer::const_iterator VertexConstIterator; 00070 //! Container for texture vertices 00071 typedef std::vector<TextureVertexType> TextureVertexContainer; 00072 //! Iterator for texture vertices 00073 typedef TextureVertexContainer::iterator TextureVertexIterator; 00074 //! ConstIterator for texture vertices 00075 typedef TextureVertexContainer::const_iterator TextureVertexConstIterator; 00076 }; 00077 00078 FREECLOTH_NAMESPACE_END 00079 00080 #endif