public class ArrayBasedWingededge extends java.lang.Object implements WingededgeInterface, NavigationInterface
Modifier and Type | Field and Description |
---|---|
private float[][] |
coordF |
private int[] |
incidentEdge |
private int[] |
leftBack |
private int[] |
leftFront |
private int |
nEdges |
private int |
nVertices |
private int[] |
rightBack |
private int[] |
rightFront |
private int[] |
source |
private int[] |
target |
Constructor and Description |
---|
ArrayBasedWingededge(int nVertices,
int nEdges) |
Modifier and Type | Method and Description |
---|---|
static float[] |
crossProduct(float[] a,
float[] b) |
int |
getEdge(int v)
Return an edge incident to vertex v
|
int |
getLeftBack(int e) |
int |
getLeftFront(int e) |
float[] |
getNormalFloat(int v)
Return the normal to a vertex in the mesh (simple float precision)
Fast version with simple Float precision, with no use of Point_ interface
|
float[] |
getPoint(int v)
Return the geometric coordinates of the point
|
int |
getRightBack(int e) |
int |
getRightFront(int e) |
int |
getSource(int e)
Return the vertex origin of edge e
|
int |
getTarget(int e)
Return the vertex target of edge e
|
boolean |
isOutgoing(int e,
int v)
Check whether edge e is outgoing from vertex v
|
void |
setEdge(int v,
int e) |
void |
setLeftBack(int e,
int eLeftBack) |
void |
setLeftFront(int e,
int eLeftFront) |
void |
setPoint(int v,
float x,
float y,
float z) |
void |
setRightBack(int e,
int eRightBack) |
void |
setRightFront(int e,
int eRightFront) |
void |
setSource(int e,
int v) |
void |
setTarget(int e,
int v) |
int |
sizeOfEdges() |
int |
sizeOfVertices()
Return the number of vertices in the triangulation
|
java.lang.String |
toString()
Return a String describing the data structure references
|
java.lang.String |
vectorToString(float[] u) |
int |
vertexDegree(int v)
Return the degree of a given vertex
|
int |
vertexDegreeSlow(int v)
Return the degree of a given vertex
This version is slightly slower (because of function calls)
|
private int nVertices
private int nEdges
private int[] leftFront
private int[] rightFront
private int[] leftBack
private int[] rightBack
private int[] source
private int[] target
private int[] incidentEdge
private float[][] coordF
public void setLeftFront(int e, int eLeftFront)
public void setRightFront(int e, int eRightFront)
public void setLeftBack(int e, int eLeftBack)
public void setRightBack(int e, int eRightBack)
public void setSource(int e, int v)
public void setTarget(int e, int v)
public void setEdge(int v, int e)
public void setPoint(int v, float x, float y, float z)
public int sizeOfVertices()
TriangulationInterface
sizeOfVertices
in interface TriangulationInterface
sizeOfVertices
in interface WingededgeInterface
public int sizeOfEdges()
sizeOfEdges
in interface WingededgeInterface
public int getLeftFront(int e)
getLeftFront
in interface WingededgeInterface
public int getRightFront(int e)
getRightFront
in interface WingededgeInterface
public int getLeftBack(int e)
getLeftBack
in interface WingededgeInterface
public int getRightBack(int e)
getRightBack
in interface WingededgeInterface
public int getSource(int e)
TriangulationInterface
getSource
in interface TriangulationInterface
public int getTarget(int e)
TriangulationInterface
getTarget
in interface TriangulationInterface
public int getEdge(int v)
TriangulationInterface
getEdge
in interface TriangulationInterface
public float[] getPoint(int v)
TriangulationInterface
getPoint
in interface TriangulationInterface
public boolean isOutgoing(int e, int v)
isOutgoing
in interface WingededgeInterface
public int vertexDegree(int v)
vertexDegree
in interface NavigationInterface
public int vertexDegreeSlow(int v)
public float[] getNormalFloat(int v)
getNormalFloat
in interface NavigationInterface
public java.lang.String toString()
toString
in class java.lang.Object
public static float[] crossProduct(float[] a, float[] b)
public java.lang.String vectorToString(float[] u)