Package mgui.geometry
Class Mesh3D.MeshFace3D
java.lang.Object
mgui.geometry.Mesh3D.MeshFace3D
- All Implemented Interfaces:
java.lang.Comparable<Mesh3D.MeshFace3D>
- Enclosing class:
- Mesh3D
public static class Mesh3D.MeshFace3D extends java.lang.Object implements java.lang.Comparable<Mesh3D.MeshFace3D>
Inner class which defines a face in a mesh
- Author:
- Andrew Reid
-
Field Summary
-
Constructor Summary
Constructors Constructor Description MeshFace3D()MeshFace3D(int a, int b, int c)MeshFace3D(Mesh3D.MeshFace3D f) -
Method Summary
Modifier and Type Method Description intcompareTo(Mesh3D.MeshFace3D f2)intgetNode(int i)booleanhasNode(int i)booleanisAdjacent(Mesh3D.MeshFace3D face)Determines whetherfaceshares at least one edge (two vertices) with this face.booleanisValid()voidreverse()voidsetIndices(int a, int b, int c)voidsetNode(int i, int index)intwhichNode(int index)Returns the index in this face of the vertex atindex(i.e., in the mesh).Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
A
public int A -
B
public int B -
C
public int C
-
-
Constructor Details
-
MeshFace3D
public MeshFace3D() -
MeshFace3D
public MeshFace3D(int a, int b, int c) -
MeshFace3D
-
-
Method Details
-
setIndices
public void setIndices(int a, int b, int c) throws java.lang.Exception- Throws:
java.lang.Exception
-
getNode
public int getNode(int i) -
whichNode
public int whichNode(int index)Returns the index in this face of the vertex atindex(i.e., in the mesh). Returns-1if the vertex is not in this face.- Parameters:
index-- Returns:
-
setNode
public void setNode(int i, int index) -
hasNode
public boolean hasNode(int i) -
isValid
public boolean isValid() -
reverse
public void reverse() -
isAdjacent
Determines whetherfaceshares at least one edge (two vertices) with this face.- Parameters:
face-- Returns:
-
compareTo
- Specified by:
compareToin interfacejava.lang.Comparable<Mesh3D.MeshFace3D>
-