HE_Mesh2014  2.0.11
Public Member Functions | Static Public Member Functions | Static Protected Member Functions | Protected Attributes | Private Attributes | Static Private Attributes | List of all members
wblut.hemesh.HE_Mesh Class Reference
+ Inheritance diagram for wblut.hemesh.HE_Mesh:

Public Member Functions

 HE_Mesh ()
 
 HE_Mesh (final HEC_Creator creator)
 
 HE_Mesh (final WB_Mesh mesh)
 
 HE_Mesh (final WB_MeshCreator mesh)
 
HE_Mesh modify (final HEM_Modifier modifier)
 
HE_Mesh modifySelected (final HEM_Modifier modifier, final HE_Selection selection)
 
HE_Mesh subdivide (final HES_Subdividor subdividor)
 
HE_Mesh subdivideSelected (final HES_Subdividor subdividor, final HE_Selection selection)
 
HE_Mesh subdivide (final HES_Subdividor subdividor, final int rep)
 
HE_Mesh subdivideSelected (final HES_Subdividor subdividor, final HE_Selection selection, final int rep)
 
HE_Mesh simplify (final HES_Simplifier simplifier)
 
HE_Mesh simplifySelected (final HES_Simplifier simplifier, final HE_Selection selection)
 
HE_Mesh get ()
 
void add (final HE_Mesh mesh)
 
void fuse (final HE_Mesh mesh)
 
void set (final HE_Mesh target)
 
float[][] getVerticesAsFloat ()
 
double[][] getVerticesAsDouble ()
 
Map< Long, Integer > vertexKeyToIndex ()
 
WB_Point[] getVerticesAsNewPoint ()
 
WB_Point[] getVerticesAsPoint ()
 
WB_Vector[] getVertexNormals ()
 
Map< Long, WB_VectorgetKeyedVertexNormals ()
 
int[][] getFacesAsInt ()
 
WB_Vector[] getFaceNormals ()
 
Map< Long, WB_VectorgetKeyedFaceNormals ()
 
WB_Point[] getFaceCenters ()
 
Map< Long, WB_PointgetKeyedFaceCenters ()
 
WB_Vector[] getEdgeNormals ()
 
Map< Long, WB_VectorgetKeyedEdgeNormals ()
 
WB_Point[] getEdgeCenters ()
 
Map< Long, WB_PointgetKeyedEdgeCenters ()
 
WB_FaceListMesh toFaceListMesh ()
 
void setVerticesFromFloat (final float[][] values)
 
void setVerticesFromPoint (final WB_Point[] values)
 
void setVerticesFromDouble (final double[][] values)
 
void setVerticesFromInt (final int[][] values)
 
WB_Polygon[] getPolygons ()
 
List< WB_PolygongetPolygonList ()
 
List< WB_TrianglegetTriangles ()
 
WB_Segment[] getSegments ()
 
WB_IndexedSegment[] getIndexedSegments ()
 
WB_Frame getFrame ()
 
HE_Mesh transform (final WB_Transform T)
 
HE_Mesh move (final double x, final double y, final double z)
 
HE_Mesh move (final WB_Coordinate v)
 
HE_Mesh moveTo (final double x, final double y, final double z)
 
HE_Mesh moveTo (final WB_Coordinate v)
 
HE_Mesh rotateAbout2PointAxis (final double angle, final double p1x, final double p1y, final double p1z, final double p2x, final double p2y, final double p2z)
 
HE_Mesh rotateAbout2PointAxis (final double angle, final WB_Coordinate p1, final WB_Coordinate p2)
 
HE_Mesh rotateAboutAxis (final double angle, final WB_Coordinate p, final WB_Coordinate a)
 
HE_Mesh rotateAboutAxis (final double angle, final double px, final double py, final double pz, final double ax, final double ay, final double az)
 
HE_Mesh scale (final double scaleFactorx, final double scaleFactory, final double scaleFactorz, final WB_Point c)
 
HE_Mesh scale (final double scaleFactor, final WB_Point c)
 
HE_Mesh scale (final double scaleFactorx, final double scaleFactory, final double scaleFactorz)
 
HE_Mesh scale (final double scaleFactor)
 
WB_Point getCenter ()
 
void resetCenter ()
 
List< HE_HalfedgegetUnpairedHalfedges ()
 
List< HE_HalfedgegetBoundaryHalfedges ()
 
void pairHalfedges ()
 
void pairHalfedges (final List< HE_Halfedge > unpairedHalfedges)
 
void capHalfedges ()
 
void uncapBoundaryHalfedges ()
 
List< HE_FacecapHoles ()
 
HE_Mesh cleanUnusedElementsByFace ()
 
HE_Mesh flipAllFaces ()
 
boolean flipEdge (final HE_Halfedge he)
 
boolean collapseHalfedge (final HE_Halfedge he)
 
boolean collapseHalfedgeBP (final HE_Halfedge he)
 
boolean collapseEdge (final HE_Halfedge e)
 
boolean collapseEdgeBP (final HE_Halfedge e, final boolean strict)
 
void deleteTwoEdgeFace (final HE_Face f)
 
void deleteTwoEdgeVertex (final HE_Vertex v)
 
void deleteTwoEdgeVertices ()
 
void fixHalfedgeVertexAssignment ()
 
void collapseDegenerateEdges ()
 
void collapseDegenerateEdges (final double d)
 
void deleteFace (final HE_Face f)
 
HE_Face deleteEdge (final HE_Halfedge e)
 
HE_Selection splitEdge (final HE_Halfedge edge, final WB_Coordinate v)
 
HE_Selection splitEdge (final Long key, final WB_Point v)
 
void splitEdge (final HE_Halfedge edge, final double x, final double y, final double z)
 
void splitEdge (final long key, final double x, final double y, final double z)
 
HE_Selection splitEdge (final HE_Halfedge edge)
 
HE_Selection splitEdge (final long key)
 
HE_Selection splitEdge (final HE_Halfedge edge, final double f)
 
HE_Selection splitEdge (final long key, final double f)
 
HE_Selection splitEdges ()
 
HE_Selection splitEdges (final double offset)
 
HE_Selection splitEdges (final HE_Selection selection)
 
HE_Selection splitEdges (final HE_Selection selection, final double offset)
 
void splitEdge (final HE_Halfedge edge, final double[] f)
 
void splitEdge (final long key, final double[] f)
 
void splitEdge (final HE_Halfedge edge, final float[] f)
 
void splitEdge (final long key, final float[] f)
 
void divideEdge (final HE_Halfedge edge, final int n)
 
void divideEdge (final long key, final int n)
 
HE_Selection splitFace (final HE_Face face, final HE_Vertex vi, final HE_Vertex vj)
 
HE_Selection splitFace (final long fkey, final long vkeyi, final long vkeyj)
 
HE_Selection splitFacesTri (final double d)
 
HE_Selection splitFacesTri ()
 
HE_Selection splitFacesTri (final HE_Selection selection)
 
HE_Selection splitFacesTri (final HE_Selection selection, final double d)
 
HE_Selection splitFacesQuad ()
 
HE_Selection splitFacesQuad (final HE_Selection sel)
 
HE_Selection splitFacesQuad (final double d)
 
HE_Selection splitFacesQuad (final HE_Selection sel, final double d)
 
HE_Selection splitFacesHybrid ()
 
HE_Selection splitFacesHybrid (final HE_Selection sel)
 
HE_Selection splitFacesCenter ()
 
HE_Selection splitFacesCenterHole ()
 
HE_Selection splitFacesCenter (final HE_Selection faces)
 
HE_Selection splitFacesCenterHole (final HE_Selection faces)
 
HE_Selection splitFacesCenter (final double d)
 
HE_Selection splitFacesCenterHole (final double d)
 
HE_Selection splitFacesCenter (final HE_Selection faces, final double d)
 
HE_Selection splitFacesCenterHole (final HE_Selection faces, final double d)
 
HE_Selection splitFacesCenter (final double d, final double c)
 
HE_Selection splitFacesCenterHole (final double d, final double c)
 
HE_Selection splitFacesCenter (final HE_Selection faces, final double d, final double c)
 
HE_Selection splitFacesCenterHole (final HE_Selection faces, final double d, final double c)
 
HE_Selection splitFacesMidEdge ()
 
HE_Selection splitFacesMidEdgeHole ()
 
HE_Selection splitFacesMidEdge (final HE_Selection selection)
 
HE_Selection splitFacesMidEdgeHole (final HE_Selection selection)
 
HE_Selection triangulateConcaveFaces ()
 
HE_Selection triangulateConcaveFaces (final List< HE_Face > sel)
 
HE_Selection triangulateConcaveFace (final long key)
 
HE_Selection triangulateConcaveFace (final HE_Face face)
 
void expandVertexToEdge (final HE_Vertex v, final HE_Face f1, final HE_Face f2, final WB_Point vn)
 
boolean validate ()
 
boolean contains (final WB_Coordinate p, final boolean isConvex)
 
void fitInAABB (final WB_AABB AABB)
 
double fitInAABBConstrained (final WB_AABB AABB)
 
void delete (final HE_Selection faces)
 
HE_Selection selectAllFaces ()
 
HE_Selection selectRandomFaces (final double chance)
 
HE_Selection selectFacesWithLabel (final int label)
 
HE_Selection selectFacesWithInternalLabel (final int label)
 
HE_Selection selectFacesWithNormal (final WB_Vector v)
 
HE_Selection selectFaces (final WB_Plane P)
 
HE_Selection selectCrossingFaces (final WB_Plane P)
 
HE_Selection selectFacesWithOtherLabel (final int label)
 
HE_Selection selectFacesWithOtherInternalLabel (final int label)
 
HE_Selection selectAllEdges ()
 
HE_Selection selectAllHalfedges ()
 
HE_Selection selectAllVertices ()
 
HE_Selection selectVerticesWithLabel (final int label)
 
HE_Selection selectVerticesWithOtherLabel (final int label)
 
HE_Selection selectVerticesWithInternalLabel (final int label)
 
HE_Selection selectVerticesWithOtherInternalLabel (final int label)
 
HE_Selection selectAllInnerBoundaryHalfedges ()
 
HE_Selection selectAllOuterBoundaryHalfedges ()
 
HE_Selection selectAllBoundaryEdges ()
 
HE_Selection selectAllBoundaryFaces ()
 
HE_Selection selectAllBoundaryVertices ()
 
HE_Face fuseCoplanarFace (final HE_Face face, final double a)
 
void fuseCoplanarFaces ()
 
void fuseCoplanarFaces (final double a)
 
void deleteCollinearVertices ()
 
void deleteDegenerateTriangles ()
 
void resetLabels ()
 
void resetVertexLabels ()
 
void resetFaceLabels ()
 
void resetFaces ()
 
void resetEdgeLabels ()
 
void resetInternalLabels ()
 
void resetVertexInternalLabels ()
 
void resetFaceInternalLabels ()
 
void resetEdgeInternalLabels ()
 
void labelFaceSelection (final HE_Selection sel, final int label)
 
void labelEdgeSelection (final HE_Selection sel, final int label)
 
void labelVertexSelection (final HE_Selection sel, final int label)
 
WB_KDTree< WB_Point, Long > getFaceTree ()
 
WB_KDTree< WB_Coordinate, Long > getVertexTree ()
 
HE_Vertex getClosestVertex (final WB_Point p, final WB_KDTree< WB_Point, Long > vertexTree)
 
WB_Point getClosestPoint (final WB_Point p, final WB_KDTree< WB_Point, Long > vertexTree)
 
void addPointInClosestFace (final WB_Point p, final WB_KDTree< WB_Coordinate, Long > vertexTree)
 
List< HE_FacegetSharedFaces (final HE_Vertex v1, final HE_Vertex v2)
 
List< WB_PolygongetBoundaryAsPolygons ()
 
List< HE_HalfedgegetBoundaryLoopHalfedges ()
 
HE_Path[] getBoundaryAsPath ()
 
void resolvePinchPoints ()
 
boolean fixNonManifoldVertices ()
 
double getArea ()
 
HE_Selection triangulate (final long key)
 
HE_Selection triangulateFaceStar (final HE_Vertex v)
 
HE_Selection triangulateFaceStar (final long vertexkey)
 
HE_Selection triangulate (final HE_Face face)
 
HE_Selection triangulate ()
 
HE_Selection triangulate (final HE_Selection sel)
 
void clean ()
 
void smooth ()
 
void smooth (final int rep)
 
void fixLoops ()
 
WB_GeometryType getType ()
 
HE_Mesh apply (final WB_Transform T)
 
WB_Vector getFaceNormal (final int id)
 
WB_Point getFaceCenter (final int id)
 
WB_Vector getVertexNormal (final int i)
 
WB_Coordinate getVertex (final int i)
 
int[][] getEdgesAsInt ()
 
WB_CoordinateSequence getPoints ()
 
int getColor ()
 
void setColor (final int color)
 
void setFaceColor (final int color)
 
void setVertexColor (final int color)
 
void setHalfedgeColor (final int color)
 
void setFaceColorWithLabel (final int color, final int i)
 
void setFaceColorWithInternalLabel (final int color, final int i)
 
void setVertexColorWithLabel (final int color, final int i)
 
void setVertexColorWithInternalLabel (final int color, final int i)
 
void setHalfedgeColorWithLabel (final int color, final int i)
 
void setHalfedgeColorWithInternalLabel (final int color, final int i)
 
void setFaceColorWithOtherLabel (final int color, final int i)
 
void setFaceColorWithOtherInternalLabel (final int color, final int i)
 
void setVertexColorWithOtherLabel (final int color, final int i)
 
void setVertexColorWithOtherInternalLabel (final int color, final int i)
 
void setHalfedgeColorWithOtherLabel (final int color, final int i)
 
void setHalfedgeColorWithOtherInternalLabel (final int color, final int i)
 
int getGenus ()
 
- Public Member Functions inherited from wblut.hemesh.HE_MeshStructure
 HE_MeshStructure ()
 
 HE_MeshStructure (final HE_MeshStructure ms)
 
void getFacesWithNormal (final WB_Coordinate n, final double ta)
 
final void add (final HE_Face f)
 
final void add (final HE_Halfedge he)
 
final void add (final HE_Vertex v)
 
final void addFaces (final HE_Face[] faces)
 
final void addFaces (final List< HE_Face > faces)
 
final void addFaces (final HE_Mesh source)
 
final void addHalfedges (final HE_Halfedge[] halfedges)
 
final void addHalfedges (final List< HE_Halfedge > halfedges)
 
final void addHalfedges (final HE_Mesh source)
 
final void addVertices (final HE_Vertex[] vertices)
 
final void addVertices (final HE_Mesh source)
 
final void addVertices (final List< HE_Vertex > vertices)
 
void clear ()
 
final void clearFaces ()
 
final void clearHalfedges ()
 
final void clearVertices ()
 
final boolean contains (final HE_Face f)
 
final boolean contains (final HE_Halfedge he)
 
final boolean contains (final HE_Vertex v)
 
final WB_AABB getAABB ()
 
final HE_Face getFaceByIndex (final int i)
 
final HE_Halfedge getHalfedgeByIndex (final int i)
 
final HE_Vertex getVertexByIndex (final int i)
 
final double[] getLimits ()
 
final double[] limits ()
 
int getNumberOfEdges ()
 
final int getNumberOfFaces ()
 
final int getNumberOfHalfedges ()
 
final int getNumberOfVertices ()
 
final void remove (final HE_Face f)
 
final void remove (final HE_Halfedge he)
 
final void remove (final HE_Vertex v)
 
final void removeFace (final int i)
 
final void removeFaces (final HE_Face[] faces)
 
final void removeFaces (final Collection< HE_Face > faces)
 
final void removeHalfedge (final int i)
 
final void removeHalfedges (final HE_Halfedge[] halfedges)
 
final void removeHalfedges (final Collection< HE_Halfedge > halfedges)
 
final void removeVertex (final int i)
 
final void removeVertices (final HE_Vertex[] vertices)
 
final void removeVertices (final Collection< HE_Vertex > vertices)
 
final List< HE_VertexgetVertices ()
 
final List< HE_HalfedgegetHalfedges ()
 
final List< HE_HalfedgegetEdges ()
 
final List< HE_FacegetFaces ()
 
final boolean containsFace (final long key)
 
final boolean containsHalfedge (final long key)
 
final boolean containsVertex (final long key)
 
final int getIndex (final HE_Face f)
 
final int getIndex (final HE_Halfedge he)
 
final int getIndex (final HE_Vertex v)
 
final void replaceFaces (final HE_Face[] faces)
 
final void replaceFaces (final HE_Mesh mesh)
 
final void replaceVertices (final HE_Mesh mesh)
 
final void replaceHalfedges (final HE_Mesh mesh)
 
final void replaceFaces (final List< HE_Face > faces)
 
final void replaceHalfedges (final HE_Halfedge[] halfedges)
 
final void replaceHalfedges (final List< HE_Halfedge > halfedges)
 
final void replaceVertices (final HE_Vertex[] vertices)
 
final void replaceVertices (final List< HE_Vertex > vertices)
 
HE_VertexIterator vItr ()
 
HE_EdgeIterator eItr ()
 
HE_HalfedgeIterator heItr ()
 
HE_FaceIterator fItr ()
 
final HE_Halfedge[] getEdgesAsArray ()
 
final List< HE_HalfedgegetEdgesAsList ()
 
final HE_Face getFaceByKey (final long key)
 
final HE_Face[] getFacesAsArray ()
 
final List< HE_FacegetFacesAsList ()
 
final HE_Halfedge getHalfedgeByKey (final long key)
 
final HE_Halfedge[] getHalfedgesAsArray ()
 
final List< HE_HalfedgegetHalfedgesAsList ()
 
final HE_Vertex getVertexByKey (final long key)
 
final HE_Vertex[] getVerticesAsArray ()
 
final List< HE_VertexgetVerticesAsList ()
 
void setData (final String s, final Object o)
 
Object getData (final String s)
 
HE_Path createPathFromIndices (final int[] vertices, final boolean loop)
 
HE_Halfedge searchHalfedgeFromTo (final HE_Vertex v0, final HE_Vertex v1)
 
- Public Member Functions inherited from wblut.hemesh.HE_Element
 HE_Element ()
 
final void setInternalLabel (final int label)
 
final void setLabel (final int label)
 
final long getKey ()
 
final int getInternalLabel ()
 
final int getLabel ()
 
int hashCode ()
 
boolean equals (final Object other)
 
void copyProperties (final HE_Element el)
 
abstract void clear ()
 
- Public Member Functions inherited from wblut.geom.WB_HasData
Object getData (String s)
 
void setData (String s, Object o)
 
- Public Member Functions inherited from wblut.geom.WB_HasColor
void setColor (int color)
 
- Public Member Functions inherited from wblut.geom.WB_Mesh
WB_AABB getAABB ()
 
int getNumberOfFaces ()
 
int getNumberOfVertices ()
 
- Public Member Functions inherited from wblut.geom.WB_Geometry
WB_Geometry apply (WB_Transform T)
 

Static Public Member Functions

static void cycleHalfedges (final List< HE_Halfedge > halfedges)
 
static void cycleHalfedgesReverse (final List< HE_Halfedge > halfedges)
 
static boolean pointIsInFace (final WB_Point p, final HE_Face f)
 
static boolean pointIsStrictlyInFace (final WB_Coordinate p, final HE_Face f)
 
- Static Public Member Functions inherited from wblut.hemesh.HE_MeshStructure
static String getStatus ()
 

Static Protected Member Functions

static void assignFaceToLoop (final HE_Face face, final HE_Halfedge halfedge)
 

Protected Attributes

int label
 
- Protected Attributes inherited from wblut.hemesh.HE_Element
final long _key
 

Private Attributes

WB_Point center
 
boolean isCenterUpdated
 
HashMap< String, Object > data
 
int meshcolor
 

Static Private Attributes

static WB_GeometryFactory gf = WB_GeometryFactory.instance()
 

Additional Inherited Members

- Public Attributes inherited from wblut.hemesh.HE_MeshStructure
HE_RAS< HE_Vertexvertices
 
HE_RAS< HE_Halfedgehalfedges
 
HE_RAS< HE_Facefaces
 
- Static Public Attributes inherited from wblut.hemesh.HE_MeshStructure
static final HET_ProgressTracker tracker
 
- Static Public Attributes inherited from wblut.geom.WB_Geometry
static final WB_GeometryFactory geometryfactory
 
- Static Protected Attributes inherited from wblut.hemesh.HE_Element
static long _currentKey
 
static final WB_GeometryFactory geometryfactory
 

Detailed Description

Half-edge mesh data structure.

Author
Frederik Vanhoutte (W:Blut)

Constructor & Destructor Documentation

wblut.hemesh.HE_Mesh.HE_Mesh ( )

Instantiates a new HE_Mesh.

wblut.hemesh.HE_Mesh.HE_Mesh ( final HEC_Creator  creator)

Constructor.

Parameters
creatorHE_Creator that generates this mesh
wblut.hemesh.HE_Mesh.HE_Mesh ( final WB_Mesh  mesh)
Parameters
mesh
wblut.hemesh.HE_Mesh.HE_Mesh ( final WB_MeshCreator  mesh)
Parameters
mesh

Member Function Documentation

void wblut.hemesh.HE_Mesh.add ( final HE_Mesh  mesh)

Add all mesh elements to this mesh. No copies are made.

Parameters
meshmesh to add
void wblut.hemesh.HE_Mesh.addPointInClosestFace ( final WB_Point  p,
final WB_KDTree< WB_Coordinate, Long >  vertexTree 
)

Split the closest face in the query point.

Parameters
pquery point
vertexTreeKD-tree from mesh (from vertexTree())
HE_Mesh wblut.hemesh.HE_Mesh.apply ( final WB_Transform  T)
static void wblut.hemesh.HE_Mesh.assignFaceToLoop ( final HE_Face  face,
final HE_Halfedge  halfedge 
)
staticprotected

Assign face to halfedge loop.

Parameters
faceface
halfedgehalfedge loop
void wblut.hemesh.HE_Mesh.capHalfedges ( )

Cap all remaining unpaired halfedges. Only use after pairHalfedges();

List<HE_Face> wblut.hemesh.HE_Mesh.capHoles ( )

Cap holes.

Returns
all new faces as FastTable<HE_Face>
void wblut.hemesh.HE_Mesh.clean ( )

Clean.

HE_Mesh wblut.hemesh.HE_Mesh.cleanUnusedElementsByFace ( )

Clean all mesh elements not used by any faces.

Returns
self
void wblut.hemesh.HE_Mesh.collapseDegenerateEdges ( )

Collapse all zero-length edges.

void wblut.hemesh.HE_Mesh.collapseDegenerateEdges ( final double  d)
Parameters
d
boolean wblut.hemesh.HE_Mesh.collapseEdge ( final HE_Halfedge  e)

Collapse edge. End vertices are averaged. Degenerate faces are removed. This function can result in non-manifold meshes.

Parameters
eedge to collapse
Returns
true, if successful
boolean wblut.hemesh.HE_Mesh.collapseEdgeBP ( final HE_Halfedge  e,
final boolean  strict 
)
Parameters
e
strict
Returns
boolean wblut.hemesh.HE_Mesh.collapseHalfedge ( final HE_Halfedge  he)

Collapse halfedge. Start vertex is removed. Degenerate faces are removed. This function can result in non-manifold meshes.

Parameters
hethe he
Returns
true, if successful
boolean wblut.hemesh.HE_Mesh.collapseHalfedgeBP ( final HE_Halfedge  he)

Collapse halfedge bp.

Parameters
hethe he
Returns
true, if successful
boolean wblut.hemesh.HE_Mesh.contains ( final WB_Coordinate  p,
final boolean  isConvex 
)

Check if point lies inside mesh.

Parameters
ppoint to check
isConvexdo fast check, convex meshes only
Returns
true or false
static void wblut.hemesh.HE_Mesh.cycleHalfedges ( final List< HE_Halfedge halfedges)
static

Cycle halfedges.

Parameters
halfedgeshalfedges to cycle
static void wblut.hemesh.HE_Mesh.cycleHalfedgesReverse ( final List< HE_Halfedge halfedges)
static

Cycle halfedges.

Parameters
halfedgeshalfedges to cycle
void wblut.hemesh.HE_Mesh.delete ( final HE_Selection  faces)

Delete face and remove all references.

Parameters
facesfaces to delete
void wblut.hemesh.HE_Mesh.deleteCollinearVertices ( )

Remove all redundant vertices in straight edges.

void wblut.hemesh.HE_Mesh.deleteDegenerateTriangles ( )
HE_Face wblut.hemesh.HE_Mesh.deleteEdge ( final HE_Halfedge  e)

Delete edge. Adjacent faces are fused.

Parameters
eedge to delete
Returns
fused face (or null)
void wblut.hemesh.HE_Mesh.deleteFace ( final HE_Face  f)

Delete face and remove all references.

Parameters
fface to delete
void wblut.hemesh.HE_Mesh.deleteTwoEdgeFace ( final HE_Face  f)

Remove a face if it has only two vertices and stitch the mesh together.

Parameters
fface to check
void wblut.hemesh.HE_Mesh.deleteTwoEdgeVertex ( final HE_Vertex  v)
Parameters
v
void wblut.hemesh.HE_Mesh.deleteTwoEdgeVertices ( )
void wblut.hemesh.HE_Mesh.divideEdge ( final HE_Halfedge  edge,
final int  n 
)

Divide edge.

Parameters
origEedge to divide
nnumber of parts
void wblut.hemesh.HE_Mesh.divideEdge ( final long  key,
final int  n 
)

Divide edge.

Parameters
keykey of edge to divide
nnumber of parts
void wblut.hemesh.HE_Mesh.expandVertexToEdge ( final HE_Vertex  v,
final HE_Face  f1,
final HE_Face  f2,
final WB_Point  vn 
)

Expand vertex to new edge.

Parameters
vvertex to expand
f1first face
f2second face
vnposition of new vertex
void wblut.hemesh.HE_Mesh.fitInAABB ( final WB_AABB  AABB)

Fit in aabb.

Parameters
AABBthe aabb
double wblut.hemesh.HE_Mesh.fitInAABBConstrained ( final WB_AABB  AABB)

Fit in aabb constrained.

Parameters
AABBthe aabb
Returns
void wblut.hemesh.HE_Mesh.fixHalfedgeVertexAssignment ( )

Fix halfedge vertex assignment.

void wblut.hemesh.HE_Mesh.fixLoops ( )

Fix loops.

boolean wblut.hemesh.HE_Mesh.fixNonManifoldVertices ( )
Returns
HE_Mesh wblut.hemesh.HE_Mesh.flipAllFaces ( )

Reverse all faces. Flips normals.

Returns
boolean wblut.hemesh.HE_Mesh.flipEdge ( final HE_Halfedge  he)
Parameters
he
Returns
void wblut.hemesh.HE_Mesh.fuse ( final HE_Mesh  mesh)

Add all mesh elements to this mesh. No copies are made. Tries to join geometry.

Parameters
meshmesh to add
HE_Face wblut.hemesh.HE_Mesh.fuseCoplanarFace ( final HE_Face  face,
final double  a 
)

Fuse all coplanar faces connected to face. New face can be concave.

Parameters
facestarting face
athe a
Returns
new face
void wblut.hemesh.HE_Mesh.fuseCoplanarFaces ( )

Fuse all planar faces. Can lead to concave faces.

void wblut.hemesh.HE_Mesh.fuseCoplanarFaces ( final double  a)

Fuse all planar faces. Can lead to concave faces.

Parameters
athe a
HE_Mesh wblut.hemesh.HE_Mesh.get ( )

Deep copy of mesh.

Returns
copy as new HE_Mesh
double wblut.hemesh.HE_Mesh.getArea ( )
Returns
HE_Path [] wblut.hemesh.HE_Mesh.getBoundaryAsPath ( )
Returns
List<WB_Polygon> wblut.hemesh.HE_Mesh.getBoundaryAsPolygons ( )
Returns
List<HE_Halfedge> wblut.hemesh.HE_Mesh.getBoundaryHalfedges ( )

Collect all boundary halfedges.

Returns
boundary halfedges
List<HE_Halfedge> wblut.hemesh.HE_Mesh.getBoundaryLoopHalfedges ( )
Returns
WB_Point wblut.hemesh.HE_Mesh.getCenter ( )

Get the center (average of all vertex positions).

Returns
the center

Implements wblut.geom.WB_Mesh.

WB_Point wblut.hemesh.HE_Mesh.getClosestPoint ( final WB_Point  p,
final WB_KDTree< WB_Point, Long >  vertexTree 
)

Return the closest point on the mesh.

Parameters
pquery point
vertexTreeKD-tree from mesh (from vertexTree())
Returns
WB_Point closest point
HE_Vertex wblut.hemesh.HE_Mesh.getClosestVertex ( final WB_Point  p,
final WB_KDTree< WB_Point, Long >  vertexTree 
)

Return the closest vertex on the mesh.

Parameters
pquery point
vertexTreeKD-tree from mesh (from vertexTree())
Returns
HE_Vertex closest vertex
int wblut.hemesh.HE_Mesh.getColor ( )
Returns

Implements wblut.geom.WB_HasColor.

WB_Point [] wblut.hemesh.HE_Mesh.getEdgeCenters ( )

Return all edge centers.

Returns
array of WB_Point.
WB_Vector [] wblut.hemesh.HE_Mesh.getEdgeNormals ( )

Return all edge normals.

Returns
array of WB_Vector.
int [][] wblut.hemesh.HE_Mesh.getEdgesAsInt ( )
Returns

Implements wblut.geom.WB_Mesh.

WB_Point wblut.hemesh.HE_Mesh.getFaceCenter ( final int  id)
Parameters
id
Returns

Implements wblut.geom.WB_Mesh.

WB_Point [] wblut.hemesh.HE_Mesh.getFaceCenters ( )

Return all face centers.

Returns
array of WB_Point.
WB_Vector wblut.hemesh.HE_Mesh.getFaceNormal ( final int  id)
Parameters
id
Returns

Implements wblut.geom.WB_Mesh.

WB_Vector [] wblut.hemesh.HE_Mesh.getFaceNormals ( )

Return all face normals.

Returns
array of WB_Vector.
int [][] wblut.hemesh.HE_Mesh.getFacesAsInt ( )

Return the faces as array of vertex indices.

Returns
2D array of int. First index gives face. Second index gives vertices.

Implements wblut.geom.WB_Mesh.

WB_KDTree<WB_Point, Long> wblut.hemesh.HE_Mesh.getFaceTree ( )

Return a KD-tree containing all face centers.

Returns
WB_KDTree
WB_Frame wblut.hemesh.HE_Mesh.getFrame ( )

Gets the frame.

Returns
the frame
int wblut.hemesh.HE_Mesh.getGenus ( )
Returns
WB_IndexedSegment [] wblut.hemesh.HE_Mesh.getIndexedSegments ( )

Gets the indexed segments.

Returns
the indexed segments
Map<Long, WB_Point> wblut.hemesh.HE_Mesh.getKeyedEdgeCenters ( )

Return all edge centers.

Returns
FastMap of WB_Point.
Map<Long, WB_Vector> wblut.hemesh.HE_Mesh.getKeyedEdgeNormals ( )

Return all edge normals.

Returns
FastMap of WB_Vector.
Map<Long, WB_Point> wblut.hemesh.HE_Mesh.getKeyedFaceCenters ( )

Return all face centers.

Returns
FastMap of WB_Point.
Map<Long, WB_Vector> wblut.hemesh.HE_Mesh.getKeyedFaceNormals ( )

Return all face normals.

Returns
FastMap of WB_Vector.
Map<Long, WB_Vector> wblut.hemesh.HE_Mesh.getKeyedVertexNormals ( )

Return all vertex normal.

Returns
FastMap of WB_Vector.
WB_CoordinateSequence wblut.hemesh.HE_Mesh.getPoints ( )
Returns

Implements wblut.geom.WB_Mesh.

List<WB_Polygon> wblut.hemesh.HE_Mesh.getPolygonList ( )

Gets the polygon list.

Returns
the polygon list
WB_Polygon [] wblut.hemesh.HE_Mesh.getPolygons ( )

Return the mesh as polygon soup.

Returns
array of WB_polygon
WB_Segment [] wblut.hemesh.HE_Mesh.getSegments ( )

Gets the segments.

Returns
the segments
List<HE_Face> wblut.hemesh.HE_Mesh.getSharedFaces ( final HE_Vertex  v1,
final HE_Vertex  v2 
)
Parameters
v1
v2
Returns
List<WB_Triangle> wblut.hemesh.HE_Mesh.getTriangles ( )
Returns
WB_GeometryType wblut.hemesh.HE_Mesh.getType ( )
Returns

Implements wblut.geom.WB_Geometry.

List<HE_Halfedge> wblut.hemesh.HE_Mesh.getUnpairedHalfedges ( )

Collect all unpaired halfedges.

Returns
the unpaired halfedges
WB_Coordinate wblut.hemesh.HE_Mesh.getVertex ( final int  i)
Parameters
i
Returns

Implements wblut.geom.WB_Mesh.

WB_Vector wblut.hemesh.HE_Mesh.getVertexNormal ( final int  i)
Parameters
i
Returns

Implements wblut.geom.WB_Mesh.

WB_Vector [] wblut.hemesh.HE_Mesh.getVertexNormals ( )

Return all vertex normal.

Returns
array of WB_Vector.
WB_KDTree<WB_Coordinate, Long> wblut.hemesh.HE_Mesh.getVertexTree ( )

Return a KD-tree containing all vertices.

Returns
WB_KDTree
double [][] wblut.hemesh.HE_Mesh.getVerticesAsDouble ( )

Return all vertex positions as an array .

Returns
2D array of double. First index gives vertex. Second index gives x-,y- or z-coordinate.
float [][] wblut.hemesh.HE_Mesh.getVerticesAsFloat ( )

Return all vertex positions as an array .

Returns
2D array of float. First index gives vertex. Second index gives x-,y- or z-coordinate.
WB_Point [] wblut.hemesh.HE_Mesh.getVerticesAsNewPoint ( )

Return all vertex positions.

Returns
array of WB_Point, values are copied.
WB_Point [] wblut.hemesh.HE_Mesh.getVerticesAsPoint ( )

Return all vertex positions.

Returns
array of WB_Cooridnate, no copies are made.
void wblut.hemesh.HE_Mesh.labelEdgeSelection ( final HE_Selection  sel,
final int  label 
)

Label edge selection.

Parameters
selthe sel
labelthe label
void wblut.hemesh.HE_Mesh.labelFaceSelection ( final HE_Selection  sel,
final int  label 
)

Label all faces of a selection.

Parameters
selselection
labellabel to use
void wblut.hemesh.HE_Mesh.labelVertexSelection ( final HE_Selection  sel,
final int  label 
)

Label vertex selection.

Parameters
selthe sel
labelthe label
HE_Mesh wblut.hemesh.HE_Mesh.modify ( final HEM_Modifier  modifier)

Modify the mesh.

Parameters
modifierHE_Modifier to apply
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.modifySelected ( final HEM_Modifier  modifier,
final HE_Selection  selection 
)

Modify selection. Elements should be part of this mesh.

Parameters
modifierHE_Modifier to apply
selectionthe selection
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.move ( final double  x,
final double  y,
final double  z 
)

Translate entire mesh.

Parameters
xthe x
ythe y
zthe z
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.move ( final WB_Coordinate  v)

Translate entire mesh.

Parameters
vthe v
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.moveTo ( final double  x,
final double  y,
final double  z 
)

Translate entire mesh to given position.

Parameters
xthe x
ythe y
zthe z
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.moveTo ( final WB_Coordinate  v)

Translate entire mesh to given position.

Parameters
vthe v
Returns
self
void wblut.hemesh.HE_Mesh.pairHalfedges ( )

Try to pair all unpaired halfedges.

void wblut.hemesh.HE_Mesh.pairHalfedges ( final List< HE_Halfedge unpairedHalfedges)

Pair halfedges.

Parameters
unpairedHalfedgesthe unpaired halfedges
static boolean wblut.hemesh.HE_Mesh.pointIsInFace ( final WB_Point  p,
final HE_Face  f 
)
static

Check if point lies inside or on edge of face.

Parameters
ppoint
fthe f
Returns
true/false
static boolean wblut.hemesh.HE_Mesh.pointIsStrictlyInFace ( final WB_Coordinate  p,
final HE_Face  f 
)
static

Check if point lies strictly inside face.

Parameters
ppoint
fthe f
Returns
true/false
void wblut.hemesh.HE_Mesh.resetCenter ( )

Reset the center to the average of all vertex positions).

void wblut.hemesh.HE_Mesh.resetEdgeInternalLabels ( )

Reset edge labels.

void wblut.hemesh.HE_Mesh.resetEdgeLabels ( )

Reset edge labels.

void wblut.hemesh.HE_Mesh.resetFaceInternalLabels ( )

Reset face labels.

void wblut.hemesh.HE_Mesh.resetFaceLabels ( )

Reset face labels.

void wblut.hemesh.HE_Mesh.resetFaces ( )

Reset faces.

void wblut.hemesh.HE_Mesh.resetInternalLabels ( )

Reset labels.

void wblut.hemesh.HE_Mesh.resetLabels ( )

Reset labels.

void wblut.hemesh.HE_Mesh.resetVertexInternalLabels ( )

Reset vertex labels.

void wblut.hemesh.HE_Mesh.resetVertexLabels ( )

Reset vertex labels.

void wblut.hemesh.HE_Mesh.resolvePinchPoints ( )
HE_Mesh wblut.hemesh.HE_Mesh.rotateAbout2PointAxis ( final double  angle,
final double  p1x,
final double  p1y,
final double  p1z,
final double  p2x,
final double  p2y,
final double  p2z 
)

Rotate entire mesh around an arbitrary axis.

Parameters
angleangle
p1xx-coordinate of first point on axis
p1yy-coordinate of first point on axis
p1zz-coordinate of first point on axis
p2xx-coordinate of second point on axis
p2yy-coordinate of second point on axis
p2zz-coordinate of second point on axis
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.rotateAbout2PointAxis ( final double  angle,
final WB_Coordinate  p1,
final WB_Coordinate  p2 
)

Rotate entire mesh around an arbitrary axis.

Parameters
angleangle
p1first point on axis
p2second point on axis
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.rotateAboutAxis ( final double  angle,
final WB_Coordinate  p,
final WB_Coordinate  a 
)

Rotate entire mesh around an arbitrary axis.

Parameters
angleangle
protation point
aaxis
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.rotateAboutAxis ( final double  angle,
final double  px,
final double  py,
final double  pz,
final double  ax,
final double  ay,
final double  az 
)
HE_Mesh wblut.hemesh.HE_Mesh.scale ( final double  scaleFactorx,
final double  scaleFactory,
final double  scaleFactorz,
final WB_Point  c 
)

Scale entire mesh around center point.

Parameters
scaleFactorxx-coordinate of scale factor
scaleFactoryy-coordinate of scale factor
scaleFactorzz-coordinate of scale factor
ccenter
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.scale ( final double  scaleFactor,
final WB_Point  c 
)

Scale entire mesh around center point.

Parameters
scaleFactorscale
ccenter
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.scale ( final double  scaleFactorx,
final double  scaleFactory,
final double  scaleFactorz 
)

Scale entire mesh around bodycenter.

Parameters
scaleFactorxx-coordinate of scale factor
scaleFactoryy-coordinate of scale factor
scaleFactorzz-coordinate of scale factor
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.scale ( final double  scaleFactor)

Scale entire mesh around bodycenter.

Parameters
scaleFactorscale
Returns
self
HE_Selection wblut.hemesh.HE_Mesh.selectAllBoundaryEdges ( )

Select all edges on boundary.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllBoundaryFaces ( )

Select all faces on boundary.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllBoundaryVertices ( )

Select all vertices on boundary.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllEdges ( )

Select all edges.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllFaces ( )

Select all faces.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllHalfedges ( )

Select all halfedges.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllInnerBoundaryHalfedges ( )

Select all halfedges on inside of boundary.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllOuterBoundaryHalfedges ( )

Select all halfedges on outside of boundary.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectAllVertices ( )

Select all vertices.

Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectCrossingFaces ( final WB_Plane  P)
Parameters
P
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectFaces ( final WB_Plane  P)
Parameters
P
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectFacesWithInternalLabel ( final int  label)
Parameters
label
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectFacesWithLabel ( final int  label)

Select all faces with given label.

Parameters
labelthe label
Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectFacesWithNormal ( final WB_Vector  v)
Parameters
v
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectFacesWithOtherInternalLabel ( final int  label)
Parameters
label
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectFacesWithOtherLabel ( final int  label)

Select all faces except with given label.

Parameters
labelthe label
Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectRandomFaces ( final double  chance)
Parameters
chance
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectVerticesWithInternalLabel ( final int  label)
Parameters
label
Returns
HE_Selection wblut.hemesh.HE_Mesh.selectVerticesWithLabel ( final int  label)

Select all vertices with given label.

Parameters
labelthe label
Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectVerticesWithOtherInternalLabel ( final int  label)

Select all vertices except with given label.

Parameters
labelthe label
Returns
the h e_ selection
HE_Selection wblut.hemesh.HE_Mesh.selectVerticesWithOtherLabel ( final int  label)

Select all vertices except with given label.

Parameters
labelthe label
Returns
the h e_ selection
void wblut.hemesh.HE_Mesh.set ( final HE_Mesh  target)

Replace mesh with deep copy of target.

Parameters
targetHE_Mesh to be duplicated
void wblut.hemesh.HE_Mesh.setColor ( final int  color)
void wblut.hemesh.HE_Mesh.setFaceColor ( final int  color)
Parameters
color
void wblut.hemesh.HE_Mesh.setFaceColorWithInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setFaceColorWithLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setFaceColorWithOtherInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setFaceColorWithOtherLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setHalfedgeColor ( final int  color)
Parameters
color
void wblut.hemesh.HE_Mesh.setHalfedgeColorWithInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setHalfedgeColorWithLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setHalfedgeColorWithOtherInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setHalfedgeColorWithOtherLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setVertexColor ( final int  color)
Parameters
color
void wblut.hemesh.HE_Mesh.setVertexColorWithInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setVertexColorWithLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setVertexColorWithOtherInternalLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setVertexColorWithOtherLabel ( final int  color,
final int  i 
)
Parameters
color
i
void wblut.hemesh.HE_Mesh.setVerticesFromDouble ( final double  values[][])

Set vertex positions to values in array.

Parameters
values2D array of double. First index is number of vertices, second index is 3 (x-,y- and z-coordinate)
void wblut.hemesh.HE_Mesh.setVerticesFromFloat ( final float  values[][])

Set vertex positions to values in array.

Parameters
values2D array of float. First index is number of vertices, second index is 3 (x-,y- and z-coordinate)
void wblut.hemesh.HE_Mesh.setVerticesFromInt ( final int  values[][])

Set vertex positions to values in array.

Parameters
values2D array of int. First index is number of vertices, second index is 3 (x-,y- and z-coordinate)
void wblut.hemesh.HE_Mesh.setVerticesFromPoint ( final WB_Point[]  values)

Set vertex positions to values in array.

Parameters
valuesarray of WB_Point.
HE_Mesh wblut.hemesh.HE_Mesh.simplify ( final HES_Simplifier  simplifier)

Simplify.

Parameters
simplifierthe simplifier
Returns
the h e_ mesh
HE_Mesh wblut.hemesh.HE_Mesh.simplifySelected ( final HES_Simplifier  simplifier,
final HE_Selection  selection 
)

Simplify.

Parameters
simplifierthe simplifier
selectionthe selection
Returns
the h e_ mesh
void wblut.hemesh.HE_Mesh.smooth ( )

Smooth.

void wblut.hemesh.HE_Mesh.smooth ( final int  rep)
Parameters
rep
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge,
final WB_Coordinate  v 
)

Insert vertex in edge.

Parameters
edgeedge to split
vposition of new vertex
Returns
selection of new vertex and new edge
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final Long  key,
final WB_Point  v 
)

Insert vertex in edge.

Parameters
keykey of edge to split
vposition of new vertex
Returns
selection of new vertex and new edge
void wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge,
final double  x,
final double  y,
final double  z 
)

Insert vertex in edge.

Parameters
edgeedge to split
xx-coordinate of new vertex
yy-coordinate of new vertex
zz-coordinate of new vertex
void wblut.hemesh.HE_Mesh.splitEdge ( final long  key,
final double  x,
final double  y,
final double  z 
)

Insert vertex in edge.

Parameters
keykey of edge to split
xx-coordinate of new vertex
yy-coordinate of new vertex
zz-coordinate of new vertex
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge)

Split edge in half.

Parameters
edgeedge to split.
Returns
selection of new vertex and new edge
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final long  key)

Split edge in half.

Parameters
keykey of edge to split.
Returns
selection of new vertex and new edge
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge,
final double  f 
)

Split edge in two parts.

Parameters
edgeedge to split
ffraction of first part (0..1)
Returns
selection of new vertex and new edge
HE_Selection wblut.hemesh.HE_Mesh.splitEdge ( final long  key,
final double  f 
)

Split edge in two parts.

Parameters
keykey of edge to split
ffraction of first part (0..1)
Returns
selection of new vertex and new edge
void wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge,
final double[]  f 
)

Split edge in multiple parts.

Parameters
edgeedge to split
farray of fractions (0..1)
void wblut.hemesh.HE_Mesh.splitEdge ( final long  key,
final double[]  f 
)

Split edge in multiple parts.

Parameters
keykey of edge to split
farray of fractions (0..1)
void wblut.hemesh.HE_Mesh.splitEdge ( final HE_Halfedge  edge,
final float[]  f 
)

Split edge in multiple parts.

Parameters
edgeedge to split
farray of fractions (0..1)
void wblut.hemesh.HE_Mesh.splitEdge ( final long  key,
final float[]  f 
)

Split edge in multiple parts.

Parameters
keykey of edge to split
farray of fractions (0..1)
HE_Selection wblut.hemesh.HE_Mesh.splitEdges ( )

Split all edges in half.

Returns
selection of new vertices and new edges
HE_Selection wblut.hemesh.HE_Mesh.splitEdges ( final double  offset)

Split all edges in half, offset the center by a given distance along the edge normal.

Parameters
offsetthe offset
Returns
selection of new vertices and new edges
HE_Selection wblut.hemesh.HE_Mesh.splitEdges ( final HE_Selection  selection)

Split edge in half.

Parameters
selectionedges to split.
Returns
selection of new vertices and new edges
HE_Selection wblut.hemesh.HE_Mesh.splitEdges ( final HE_Selection  selection,
final double  offset 
)

Split edge in half, offset the center by a given distance along the edge normal.

Parameters
selectionedges to split.
offsetthe offset
Returns
selection of new vertices and new edges
HE_Selection wblut.hemesh.HE_Mesh.splitFace ( final HE_Face  face,
final HE_Vertex  vi,
final HE_Vertex  vj 
)

Divide face along two vertices.

Parameters
faceface to divide
vifirst vertex
vjsecond vertex
Returns
new face and edge
HE_Selection wblut.hemesh.HE_Mesh.splitFace ( final long  fkey,
final long  vkeyi,
final long  vkeyj 
)

Divide face along two vertices.

Parameters
fkeykey of face
vkeyikey of first vertex
vkeyjkey of second vertex
Returns
new face and edge
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( )
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( final HE_Selection  faces)
Parameters
faces
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( final double  d)
Parameters
d
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( final HE_Selection  faces,
final double  d 
)
Parameters
faces
d
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( final double  d,
final double  c 
)
Parameters
d
c
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenter ( final HE_Selection  faces,
final double  d,
final double  c 
)
Parameters
faces
d
c
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( )
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( final HE_Selection  faces)
Parameters
faces
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( final double  d)
Parameters
d
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( final HE_Selection  faces,
final double  d 
)
Parameters
faces
d
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( final double  d,
final double  c 
)
Parameters
d
c
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesCenterHole ( final HE_Selection  faces,
final double  d,
final double  c 
)
Parameters
faces
d
c
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesHybrid ( )

Hybrid split faces: midsplit for triangles, quad split otherwise.

Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesHybrid ( final HE_Selection  sel)

Hybrid split faces: midsplit for triangles, quad split otherwise.

Parameters
selthe sel
Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesMidEdge ( )

Midedge split faces.

Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesMidEdge ( final HE_Selection  selection)

Mid edge split selected faces.

Parameters
selectionselection to split
Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesMidEdgeHole ( )

Mid edge split faces.

Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesMidEdgeHole ( final HE_Selection  selection)
Parameters
selection
Returns
HE_Selection wblut.hemesh.HE_Mesh.splitFacesQuad ( )

Quad split faces.

Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesQuad ( final HE_Selection  sel)

Quad split selected faces.

Parameters
selselection to split
Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesQuad ( final double  d)

Quad split faces.

Parameters
d
Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesQuad ( final HE_Selection  sel,
final double  d 
)

Quad split selected faces.

Parameters
selselection to split
d
Returns
selection of new faces and new vertices
HE_Selection wblut.hemesh.HE_Mesh.splitFacesTri ( final double  d)

Tri split faces with offset along face normal.

Parameters
doffset along face normal
Returns
selection of new faces and new vertex
HE_Selection wblut.hemesh.HE_Mesh.splitFacesTri ( )

Tri split faces.

Returns
selection of new faces and new vertex
HE_Selection wblut.hemesh.HE_Mesh.splitFacesTri ( final HE_Selection  selection)

Tri split faces.

Parameters
selectionface selection to split
Returns
selection of new faces and new vertex
HE_Selection wblut.hemesh.HE_Mesh.splitFacesTri ( final HE_Selection  selection,
final double  d 
)

Tri split faces with offset along face normal.

Parameters
selectionface selection to split
doffset along face normal
Returns
selection of new faces and new vertex
HE_Mesh wblut.hemesh.HE_Mesh.subdivide ( final HES_Subdividor  subdividor)

Subdivide the mesh.

Parameters
subdividorHE_Subdividor to apply
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.subdivide ( final HES_Subdividor  subdividor,
final int  rep 
)

Subdivide the mesh a number of times.

Parameters
subdividorHE_Subdividor to apply
repsubdivision iterations. WARNING: higher values will lead to unmanageable number of faces.
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.subdivideSelected ( final HES_Subdividor  subdividor,
final HE_Selection  selection 
)

Subdivide selection of the mesh.

Parameters
subdividorHE_Subdividor to apply
selectionHE_Selection
Returns
self
HE_Mesh wblut.hemesh.HE_Mesh.subdivideSelected ( final HES_Subdividor  subdividor,
final HE_Selection  selection,
final int  rep 
)

Subdivide a selection of the mesh a number of times.

Parameters
subdividorHE_Subdividor to apply
selectionHE_Selection initial selection
repsubdivision iterations
Returns
self
WB_FaceListMesh wblut.hemesh.HE_Mesh.toFaceListMesh ( )
Returns
HE_Mesh wblut.hemesh.HE_Mesh.transform ( final WB_Transform  T)

Apply transform to entire mesh.

Parameters
TWB_Transform to apply
Returns
self
HE_Selection wblut.hemesh.HE_Mesh.triangulate ( final long  key)

Triangulate face.

Parameters
keykey of face
Returns
HE_Selection wblut.hemesh.HE_Mesh.triangulate ( final HE_Face  face)
Parameters
face
Returns
HE_Selection wblut.hemesh.HE_Mesh.triangulate ( )

Triangulate all faces.

Returns
HE_Selection wblut.hemesh.HE_Mesh.triangulate ( final HE_Selection  sel)

Triangulate.

Parameters
selthe sel
Returns
HE_Selection wblut.hemesh.HE_Mesh.triangulateConcaveFace ( final long  key)

Triangulate face if concave.

Parameters
keykey of face
HE_Selection wblut.hemesh.HE_Mesh.triangulateConcaveFace ( final HE_Face  face)

Triangulate face if concave.

Parameters
facekey of face
HE_Selection wblut.hemesh.HE_Mesh.triangulateConcaveFaces ( )

Triangulate all concave faces.

HE_Selection wblut.hemesh.HE_Mesh.triangulateConcaveFaces ( final List< HE_Face sel)
Parameters
sel
HE_Selection wblut.hemesh.HE_Mesh.triangulateFaceStar ( final HE_Vertex  v)
Parameters
v
Returns
HE_Selection wblut.hemesh.HE_Mesh.triangulateFaceStar ( final long  vertexkey)
Parameters
vertexkey
Returns
void wblut.hemesh.HE_Mesh.uncapBoundaryHalfedges ( )

Uncap halfedges.

boolean wblut.hemesh.HE_Mesh.validate ( )

Check consistency of datastructure.

Returns
true or false
Map<Long, Integer> wblut.hemesh.HE_Mesh.vertexKeyToIndex ( )

Vertex key to index.

Returns
the map

Member Data Documentation

WB_Point wblut.hemesh.HE_Mesh.center
private
HashMap<String, Object> wblut.hemesh.HE_Mesh.data
private
WB_GeometryFactory wblut.hemesh.HE_Mesh.gf = WB_GeometryFactory.instance()
staticprivate
boolean wblut.hemesh.HE_Mesh.isCenterUpdated
private
int wblut.hemesh.HE_Mesh.label
protected
int wblut.hemesh.HE_Mesh.meshcolor
private

The documentation for this class was generated from the following file: