Subversion Repositories gelsvn

Rev

Rev 39 | Rev 113 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 39 Rev 89
Line 7... Line 7...
7
 
7
 
8
#include "Vertex.h"
8
#include "Vertex.h"
9
#include "HalfEdge.h"
9
#include "HalfEdge.h"
10
#include "Face.h"
10
#include "Face.h"
11
 
11
 
12
 
-
 
13
 
-
 
14
namespace HMesh
12
namespace HMesh
15
{
13
{
16
	class VertexCirculator;
14
	class VertexCirculator;
17
	class FaceCirculator;
15
	class FaceCirculator;
18
 
16
 
19
	/** A Data structure representing an open or closed manifold.
17
	/** \brief A Data structure representing an open or closed manifold.
-
 
18
 
20
			Manifold keeps lists of the entities making up a halfedge mesh
19
			Manifold keeps lists of the entities making up a halfedge mesh
21
			and provides basic functions for creating new faces, halfedges
20
			and provides basic functions for creating new faces, halfedges
22
			and vertices. There are also primitive operations for editing 
21
			and vertices. There are also primitive operations for editing 
23
			such as edge collapse. */
22
			such as edge collapse. */
24
	
-
 
25
	struct Manifold
23
	struct Manifold
26
	{
24
	{
27
		std::list<Vertex> vertex_db;
25
		std::list<Vertex> vertex_db;
28
		std::list<Face> face_db;
26
		std::list<Face> face_db;
29
		std::list<HalfEdge> halfedge_db;
27
		std::list<HalfEdge> halfedge_db;
30
 
28
 
31
		/** Remove a face if it contains only two edges. This is an auxiliary
29
		/** Remove a face if it contains only two edges.
-
 
30
 
32
				function called from collapse_halfedge. */
31
		This is an auxiliary function called from collapse_halfedge. */
33
		void remove_face_if_degenerate(HalfEdgeIter fi);
32
		void remove_face_if_degenerate(HalfEdgeIter fi);
34
 
33
 
-
 
34
		/** Empty copy constructor.
-
 
35
				
35
		/** Copying a manifold will not work, since faces, vertices, and
36
		Copying a manifold will not work, since faces, vertices, and
36
				halfedges contain iterators pointing to other faces, vertices,
37
				halfedges contain iterators pointing to other faces, vertices,
37
				and halfedges. These pointers would need to be changed if the 
38
				and halfedges. These pointers would need to be changed if the 
38
				mesh were copied. In other words, we would need to walk the
39
				mesh were copied. In other words, we would need to walk the
39
				entire mesh. This may be required but it should not be an 
40
				entire mesh. This may be required but it should not be an 
40
				operation that is easily invoked by calling the copy constructor.
41
				operation that is easily invoked by calling the copy constructor.
41
				Hence, this operator is made private.		*/
42
				Hence, this operator is made private.		*/
42
		Manifold(const Manifold& m2) {}
43
		Manifold(const Manifold& m2) {}
43
 
44
 
-
 
45
		/** Empty assignment operator.
-
 
46
				
44
		/** The assignment operator is private for the same reason that the
47
		The assignment operator is private for the same reason that the
45
				copy constructor is private. */
48
				copy constructor is private. */
46
		const Manifold& operator=(const Manifold& m2) {}
49
		const Manifold& operator=(const Manifold& m2) {}
47
 
50
 
48
		public:
51
		public:
49
	
52