glc_line.h

Go to the documentation of this file.
00001 /****************************************************************************
00002 
00003  This file is part of the GLC-lib library.
00004  Copyright (C) 2005-2008 Laurent Ribon (laumaya@users.sourceforge.net)
00005  http://glc-lib.sourceforge.net
00006 
00007  GLC-lib is free software; you can redistribute it and/or modify
00008  it under the terms of the GNU Lesser General Public License as published by
00009  the Free Software Foundation; either version 3 of the License, or
00010  (at your option) any later version.
00011 
00012  GLC-lib is distributed in the hope that it will be useful,
00013  but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015  GNU Lesser General Public License for more details.
00016 
00017  You should have received a copy of the GNU Lesser General Public License
00018  along with GLC-lib; if not, write to the Free Software
00019  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
00020 
00021  *****************************************************************************/
00022 
00023 #ifndef GLC_LINE_H_
00024 #define GLC_LINE_H_
00025 
00026 #include "glc_geometry.h"
00027 
00028 #include "../glc_config.h"
00029 
00032 
00035 
00036 
00037 class GLC_LIB_EXPORT GLC_Line : public GLC_Geometry
00038 {
00040 
00042 
00043 public:
00045         GLC_Line(const GLC_Point3d &, const GLC_Point3d &);
00046 
00048         GLC_Line(const GLC_Line&);
00049 
00051         virtual ~GLC_Line();
00052 
00054 
00056 
00058 
00059 public:
00060 
00062         inline GLC_Point3d point1(void) const
00063         {return m_Point1;}
00064 
00066         inline GLC_Point3d point2(void) const
00067         {return m_Point2;}
00068 
00070         virtual const GLC_BoundingBox& boundingBox(void);
00071 
00073         virtual GLC_Geometry* clone() const;
00074 
00076 
00078 
00080 
00081 public:
00083         void setCoordinate(const GLC_Point3d &, const GLC_Point3d &);
00084 
00086         inline void setColor(const QColor& color);
00087 
00088 
00090 
00092 
00094 
00095 
00096 private:
00098 
00099         virtual void glDraw(const GLC_RenderProperties&);
00100 
00102 
00104 // Private Member
00106 
00107 private:
00109         GLC_Point3d m_Point1;
00110 
00112         GLC_Point3d m_Point2;
00113 
00114 };
00115 
00116 #endif /* GLC_LINE_H_ */

SourceForge.net Logo

©2005-2011 Laurent Ribon