Files
LBPM/analysis/decl.h

64 lines
944 B
C
Raw Normal View History

2018-07-27 16:23:39 -04:00
#include <vector>
2018-09-09 23:51:52 -04:00
#include "analysis/pmmc.h"
2018-07-27 16:23:39 -04:00
/*
Doubly-connected edge list (DECL)
*/
// Vertex structure
class Vertex{
public:
Vertex();
~Vertex();
void add(Point P);
2018-09-11 16:01:22 -04:00
void assign( int idx, Point P);
int size();
Point coords(int idx);
int IncidentEdge();
2018-07-27 16:23:39 -04:00
private:
std::vector<double> vertex_data;
2018-09-11 16:01:22 -04:00
int size_;
2018-07-27 16:23:39 -04:00
};
// Halfedge structure
// Face
class Halfedge{
public:
Halfedge();
~Halfedge();
2018-09-11 16:09:18 -04:00
int v1(int edge);
int v2(int edge);
2018-09-11 16:01:22 -04:00
int twin(int edge);
int face(int edge);
int next(int edge);
int prev(int edge);
int size();
2018-07-30 16:51:37 -04:00
2018-09-11 16:01:22 -04:00
Array<int> data;
2018-07-27 16:23:39 -04:00
private:
2018-09-11 16:01:22 -04:00
int size_;
2018-07-27 16:23:39 -04:00
};
// DECL
class DECL{
public:
DECL();
~DECL();
2018-09-11 16:01:22 -04:00
int face();
2018-07-27 16:23:39 -04:00
Vertex vertex;
Halfedge halfedge;
2018-07-30 16:51:37 -04:00
void LocalIsosurface(const DoubleArray A, double value, int i, int j, int k);
2018-09-11 16:01:22 -04:00
int Face(int index);
2018-07-27 16:23:39 -04:00
double origin(int edge);
double EdgeAngle(int edge);
Point TriNormal(int edge);
2018-09-11 16:01:22 -04:00
int TriangleCount;
int VertexCount;
2018-07-30 16:51:37 -04:00
2018-07-27 16:23:39 -04:00
private:
2018-09-11 16:01:22 -04:00
Array <int> FaceData;
2018-07-27 16:23:39 -04:00
};