Subversion Repositories gelsvn

Rev

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

Rev 443 Rev 595
Line 1... Line -...
1
/**********************************************************************
-
 
2
 
1
/**
3
polygonizer.h
2
    @file Polygonizer.h
4
 
-
 
5
This is Jules Bloomenthal's implicit surface polygonizer from GRAPHICS 
3
 This is Jules Bloomenthal's implicit surface polygonizer from GRAPHICS 
6
GEMS IV. Bloomenthal's polygonizer is still used and the present code
4
 GEMS IV. Bloomenthal's polygonizer is still used and the present code
7
is simply the original code morphed into C++.
5
 is simply the original code morphed into C++.
8
 
-
 
9
J. Andreas Bærentzen 2003.
-
 
10
 
6
 */
11
**********************************************************************/
-
 
12
 
7
 
13
#ifndef __GEOMETRY_POLYGONIZER_H
8
#ifndef __GEOMETRY_POLYGONIZER_H
14
#define __GEOMETRY_POLYGONIZER_H
9
#define __GEOMETRY_POLYGONIZER_H
15
 
10
 
16
#include <vector>
11
#include <vector>
Line 92... Line 87...
92
			int no_triangles() const
87
			int no_triangles() const
93
				{
88
				{
94
					return gtriangles.size();
89
					return gtriangles.size();
95
				}
90
				}
96
 
91
 
97
			/** Return number of vertices generated after the polygonization.
92
			/** Ret urn number of vertices generated after the polygonization.
98
					Call this function only when march has been called. */
93
					Call this function only when march has been called. */
99
			int no_vertices() const
94
			int no_vertices() const
100
				{
95
				{
101
					return gvertices.size();
96
					return gvertices.size();
102
				}
97
				}
Line 109... Line 104...
109
				{
104
				{
110
					return gnormals.size();
105
					return gnormals.size();
111
				}
106
				}
112
	
107
	
113
			/// Return triangle with index i. 
108
			/// Return triangle with index i. 
114
				TRIANGLE& get_triangle(int i) 
109
				TRIANGLE& get_triangle(int i)   
115
					{
110
					{
116
						return gtriangles[i];
111
						return gtriangles[i];
117
					}
112
					}
118
 
113
 
119
				/// Return vertex with index i. 
114
				/// Return vertex with index i.