• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

PolyVoxCore/include/PolyVoxCore/SurfaceEdge.h

Go to the documentation of this file.
00001 /*******************************************************************************
00002 Copyright (c) 2005-2009 David Williams
00003 
00004 This software is provided 'as-is', without any express or implied
00005 warranty. In no event will the authors be held liable for any damages
00006 arising from the use of this software.
00007 
00008 Permission is granted to anyone to use this software for any purpose,
00009 including commercial applications, and to alter it and redistribute it
00010 freely, subject to the following restrictions:
00011 
00012     1. The origin of this software must not be misrepresented; you must not
00013     claim that you wrote the original software. If you use this software
00014     in a product, an acknowledgment in the product documentation would be
00015     appreciated but is not required.
00016 
00017     2. Altered source versions must be plainly marked as such, and must not be
00018     misrepresented as being the original software.
00019 
00020     3. This notice may not be removed or altered from any source
00021     distribution.   
00022 *******************************************************************************/
00023 
00024 #ifndef __PolyVox_SurfaceEdge_H__
00025 #define __PolyVox_SurfaceEdge_H__
00026 
00027 #include "SurfaceTypes.h"
00028 
00029 namespace PolyVox
00030 {
00031     class SurfaceEdge
00032     {
00033     public:
00034         SurfaceEdge(const SurfaceVertexIterator& targetToSet,const SurfaceVertexIterator& sourceToSet);
00035 
00036         friend bool operator == (const SurfaceEdge& lhs, const SurfaceEdge& rhs);
00037         friend bool operator < (const SurfaceEdge& lhs, const SurfaceEdge& rhs);
00038 
00039 
00040         std::string tostring(void);
00041 
00042         bool isDegenerate(void);
00043 
00044         const SurfaceVertexIterator& getTarget(void) const;
00045         const SurfaceVertexIterator& getSource(void) const;
00046         const SurfaceEdgeIterator& getOtherHalfEdge(void) const;
00047         const SurfaceEdgeIterator& getPreviousHalfEdge(void) const;
00048         const SurfaceEdgeIterator& getNextHalfEdge(void) const;
00049         const SurfaceTriangleIterator& getTriangle(void) const;
00050 
00051         void setPreviousHalfEdge(const SurfaceEdgeIterator& previousHalfEdgeToSet);
00052         void setNextHalfEdge(const SurfaceEdgeIterator& nextHalfEdgeToSet);
00053         void setTriangle(const SurfaceTriangleIterator& triangleToSet);
00054 
00055         void pairWithOtherHalfEdge(const SurfaceEdgeIterator& otherHalfEdgeToPair);
00056 
00057     private:
00058         SurfaceVertexIterator target;
00059         SurfaceVertexIterator source;
00060 
00061         SurfaceEdgeIterator previousHalfEdge;
00062         SurfaceEdgeIterator nextHalfEdge;
00063         SurfaceEdgeIterator otherHalfEdge;
00064 
00065         SurfaceTriangleIterator triangle;
00066     };  
00067 }
00068 
00069 #endif

Generated on Sat Nov 19 2011 00:27:31 for PolyVox by  doxygen 1.7.1