|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--bool.Vertex
Represents of a 3d face vertex.
See:
D. H. Laidlaw, W. B. Trumbore, and J. F. Hughes.
"Constructive Solid Geometry for Polyhedral Objects"
SIGGRAPH Proceedings, 1986, p.161.
Field Summary | |
static int |
BOUNDARY
vertex status if it on the boundary of a solid |
static int |
INSIDE
vertex status if it is inside a solid |
static int |
OUTSIDE
vertex status if it is outside a solid |
static int |
UNKNOWN
vertex status if it is still unknown |
double |
x
vertex coordinate in X |
double |
y
vertex coordinate in Y |
double |
z
vertex coordinate in Z |
Constructor Summary | |
Vertex(double x,
double y,
double z,
javax.vecmath.Color3f color)
Constructs a vertex with unknown status |
|
Vertex(double x,
double y,
double z,
javax.vecmath.Color3f color,
int status)
Constructs a vertex with a definite status |
|
Vertex(javax.vecmath.Point3d position,
javax.vecmath.Color3f color)
Constructs a vertex with unknown status |
|
Vertex(javax.vecmath.Point3d position,
javax.vecmath.Color3f color,
int status)
Constructs a vertex with definite status |
Method Summary | |
void |
addAdjacentVertex(bool.Vertex adjacentVertex)
Sets a vertex as being adjacent to it |
java.lang.Object |
clone()
Clones the vertex object |
boolean |
equals(java.lang.Object anObject)
Checks if an vertex is equal to another. |
bool.Vertex[] |
getAdjacentVertices()
Gets an array with the adjacent vertices |
javax.vecmath.Color3f |
getColor()
Gets the vertex color |
javax.vecmath.Point3d |
getPosition()
Gets the vertex position |
int |
getStatus()
Gets the vertex status |
void |
mark(int status)
Sets the vertex status, setting equally the adjacent ones |
void |
setStatus(int status)
Sets the vertex status |
java.lang.String |
toString()
Makes a string definition for the Vertex object |
Methods inherited from class java.lang.Object |
getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public double x
public double y
public double z
public static final int UNKNOWN
public static final int INSIDE
public static final int OUTSIDE
public static final int BOUNDARY
Constructor Detail |
public Vertex(javax.vecmath.Point3d position, javax.vecmath.Color3f color)
position
- vertex positioncolor
- vertex colorpublic Vertex(double x, double y, double z, javax.vecmath.Color3f color)
x
- coordinate on the x axisy
- coordinate on the y axisz
- coordinate on the z axiscolor
- vertex colorpublic Vertex(javax.vecmath.Point3d position, javax.vecmath.Color3f color, int status)
position
- vertex positioncolor
- vertex colorstatus
- vertex status - UNKNOWN, BOUNDARY, INSIDE or OUTSIDEpublic Vertex(double x, double y, double z, javax.vecmath.Color3f color, int status)
x
- coordinate on the x axisy
- coordinate on the y axisz
- coordinate on the z axiscolor
- vertex colorstatus
- vertex status - UNKNOWN, BOUNDARY, INSIDE or OUTSIDEMethod Detail |
public java.lang.Object clone()
clone
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object anObject)
equals
in class java.lang.Object
anObject
- the other vertex to be tested
public void setStatus(int status)
status
- vertex status - UNKNOWN, BOUNDARY, INSIDE or OUTSIDEpublic javax.vecmath.Point3d getPosition()
public bool.Vertex[] getAdjacentVertices()
public int getStatus()
public javax.vecmath.Color3f getColor()
public void addAdjacentVertex(bool.Vertex adjacentVertex)
adjacentVertex
- an adjacent vertexpublic void mark(int status)
status
- new status to be set
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |