30 _strips(copy._strips),
31 _opposite(copy._opposite)
41 return (_vi_a == vi || _vi_b == vi);
50 return ((_vi_a == other._vi_a && _vi_b == other._vi_b) ||
51 (_vi_b == other._vi_a && _vi_a == other._vi_b));
61 return std::min(
this, _opposite);
67 INLINE
bool EggMesherEdge::
69 return _vi_a == other._vi_a && _vi_b == other._vi_b;
75 INLINE
bool EggMesherEdge::
77 return !operator == (other);
86 if (_vi_a != other._vi_a) {
87 return _vi_a < other._vi_a;
89 return _vi_b < other._vi_b;
99 return (a - b).length();
111 LVector3d v = (a - b);
112 return LVecBase3d(fabs(v[0]), fabs(v[1]), fabs(v[2]));
EggMesherEdge(int vi_a, int vi_b)
Defines an edge as a pair of vertices.
EggVertex * get_vertex(int index) const
Returns the vertex in the pool with the indicated index number, or NULL if no vertices have that inde...
LVertexd get_pos3() const
Valid if get_num_dimensions() returns 3 or 4.
LVecBase3d compute_box(const EggVertexPool *vertex_pool) const
Returns a 3-component vector that represents the lengths of the sides of the smalled axis-aligned box...
bool matches(const EggMesherEdge &other) const
Returns true if this edge represents the same line segment as the other edge, in either direction.
bool contains_vertex(int vi) const
Returns true if the edge contains the indicated vertex index, false otherwise.
bool operator<(const EggMesherEdge &other) const
Defines an arbitrary ordering for edges, used for putting edges in a sorted container.
EggMesherEdge * common_ptr()
Returns an arbitrary pointer that is used to represent both this edge and its opposite.
Represents one edge of a triangle, as used by the EggMesher to discover connected triangles.
double compute_length(const EggVertexPool *vertex_pool) const
Returns the length of the edge in model units.
A collection of vertices.