00001 #ifndef NODE_POLYGON_H 00002 #define NODE_POLYGON_H 00003 00004 /* 00005 00006 GLT OpenGL C++ Toolkit (LGPL) 00007 Copyright (C) 2000-2002 Nigel Stewart 00008 00009 Email: nigels.com@gmail.com 00010 WWW: http://www.nigels.com/glt/ 00011 00012 This library is free software; you can redistribute it and/or 00013 modify it under the terms of the GNU Lesser General Public 00014 License as published by the Free Software Foundation; either 00015 version 2.1 of the License, or (at your option) any later version. 00016 00017 This library is distributed in the hope that it will be useful, 00018 but WITHOUT ANY WARRANTY; without even the implied warranty of 00019 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00020 Lesser General Public License for more details. 00021 00022 You should have received a copy of the GNU Lesser General Public 00023 License along with this library; if not, write to the Free Software 00024 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00025 00026 */ 00027 00034 /* 00035 #include <glt/shape.h> 00036 #include <math/vector3.h> 00037 00038 #include <vector> 00039 00041 00042 class GltPolygon : public GltShape 00043 { 00044 public: 00045 GltPolygon(); 00046 ~GltPolygon(); 00047 00048 virtual void draw() const; 00049 virtual bool boundingBox(Vector &min,Vector &max) const; 00050 virtual std::string description() const; 00051 00052 // 00053 // Get/set 00054 // 00055 00056 const std::vector<Vector> &points() const; 00057 const std::vector<Vector> &normals() const; 00058 const Vector &normal() const; 00059 00060 std::vector<Vector> &points(); 00061 std::vector<Vector> &normals(); 00062 Vector &normal(); 00063 00064 private: 00065 00066 std::vector<Vector> _points; 00067 std::vector<Vector> _normals; 00068 Vector _normal; 00069 }; 00070 00071 */ 00072 00073 #endif