Main Page   Class Hierarchy   Compound List   File List   Compound Members  

Point.h

00001 // Mesh Algorithms: a library of algorithms to manipulate 3D meshes
00002 // Copyright (C) 2001 Tim Garthwaite and Jason Reposa
00003 
00004 // This library is free software; you can redistribute it and/or
00005 // modify it under the terms of the GNU Lesser General Public
00006 // License as published by the Free Software Foundation; either
00007 // version 2.1 of the License, or (at your option) any later version.
00008 
00009 // This library is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012 // Lesser General Public License for more details.
00013 
00014 // You should have received a copy of the GNU Lesser General Public
00015 // License along with this library; if not, write to the Free Software
00016 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017 
00018 #ifndef POINT_H
00019 #define POINT_H
00020 
00021 #include "options.h"
00022 #include <cstdio>
00023 #include <string>
00024 #include <GL/gl.h>
00025 
00027 class Point {
00028   GLfloat p[4]; 
00029 
00030  public:
00031 
00033   Point(GLfloat x = 0.0f, 
00034    GLfloat y = 0.0f, 
00035    GLfloat z = 0.0f, 
00036    GLfloat w = 1.0f); 
00037 
00038   GLfloat x() const; 
00039   GLfloat y() const; 
00040   GLfloat z() const; 
00041   GLfloat w() const; 
00042 
00043   GLfloat &x(); 
00044   GLfloat &y(); 
00045   GLfloat &z(); 
00046   GLfloat &w(); 
00047 
00049   GLvoid setPoints(GLfloat x, GLfloat y, GLfloat z, GLfloat w = 1.0f);
00050 
00052   std::string toString();
00053 
00054 };
00055 
00056 #endif

Generated on Fri Dec 21 00:16:48 2001 for Mesh Decimation by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001