IsoSurface Rendering of an AR Representation

rlaramee
Class SharedVertex

java.lang.Object
  |
  +--rlaramee.SharedVertex
Direct Known Subclasses:
SharedEdgeVertex, SharedFacialVertex

public class SharedVertex
extends java.lang.Object

Description: The purpose of the SharedVertex object is to avoid paging. When a finer resolution octree node discovers that it has a vertex that is either on the face or the edge of a coarser resolution (adjacent) neighboring node, the finer resolution node instantiates a SharedVertex object and adds it to the coarser resolution neighbor's sharedVertexList. Then when Marching Cubes is done, a second pass is made through all of the coarser resolution nodes with a non-empty sharedVertexList, and then their triangles are updated. The SharedVertex object is used to remember state information such as:

  1. The TriangleVertex that is shared
  2. the edge of the coarser cube the SharedVertex may be on
  3. the face of the coarser cube the SharedVertex may be on
  4. the octant that the finer resolution node responsible for generating the sharedVertex is in

start date Thur 29 Jun 00

Version:
1.0
Author:
Robert S Laramee
See Also:

Field Summary
protected  byte coarseFace
          range is from 0 - 7
protected  byte fineOctant
          range is from 0 - 7
protected  TriangleVertex triangleVertex
          either an IsoXvertex, IsoYvertex, or IsoZvertex
 
Constructor Summary
SharedVertex(TriangleVertex triangleVertex)
          constructor
 
Method Summary
 byte getCoarseFace()
           
 byte getFineOctant()
           
 short getSourceResolution()
          "Source Resolution" is the resolution of the octree node (and associated cube) that was responsible for identifying, creating, and adding this shared vertex to the octree node that has it now (as a member).
 TriangleVertex getTriangleVertex()
           
 boolean isEqual(SharedVertex otherOne)
           
 boolean onSameFace(SharedVertex otherOne)
           
 boolean setCoarseFace(byte face)
           
 boolean setFineOctant(byte octant)
          This method is called from OctreeNode.onCoarseEdge()
 void setSourceResolution(short newRes)
           
 boolean setTriangleVertex(TriangleVertex tv)
           
 java.lang.String toShortString()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

triangleVertex

protected TriangleVertex triangleVertex
either an IsoXvertex, IsoYvertex, or IsoZvertex

fineOctant

protected byte fineOctant
range is from 0 - 7

coarseFace

protected byte coarseFace
range is from 0 - 7
Constructor Detail

SharedVertex

public SharedVertex(TriangleVertex triangleVertex)
constructor
Method Detail

getTriangleVertex

public TriangleVertex getTriangleVertex()
Returns:
the TriangleVertex object belonging to this SharedVertex

setTriangleVertex

public boolean setTriangleVertex(TriangleVertex tv)
Parameters:
the - TriangleVertex object belonging to this SharedVertex
Returns:
TRUE if the set() was successful

getFineOctant

public byte getFineOctant()
Returns:
the octant in which the finer neighbor responsible for instantiating this SharedVertex lies.

setFineOctant

public boolean setFineOctant(byte octant)
This method is called from OctreeNode.onCoarseEdge()

Parameters:
the - octant in which the finer neighbor responsible for instantiating this SharedVertex lies.
Returns:
TRUE if the set() was successful

getCoarseFace

public byte getCoarseFace()
Returns:
the coarse face on which this SharedVertex lies

setCoarseFace

public boolean setCoarseFace(byte face)
Parameters:
the - coarse face on which this SharedVertex lies
Returns:
TRUE if the set() was successful

getSourceResolution

public short getSourceResolution()
"Source Resolution" is the resolution of the octree node (and associated cube) that was responsible for identifying, creating, and adding this shared vertex to the octree node that has it now (as a member). e.g. an octree node at 128^3 resolution could add a shared vertex object onto another octree node's shared vertex list whose resolution is 64^3, 32^3, or 16^3 etc. Hence, "source resolution" is the resolution of the octree node that is the source of this shared vertex object.

setSourceResolution

public void setSourceResolution(short newRes)
Parameters:
newRes - the resolution of this shared vertex

isEqual

public boolean isEqual(SharedVertex otherOne)
Parameters:
otherOne - another SharedVertex object
Returns:
TRUE if it is the same as this one

onSameFace

public boolean onSameFace(SharedVertex otherOne)
Parameters:
otherOne - another SharedVertex object
Returns:
TRUE if the given shared triangle vertex is on the same coarse cube face as this one

toShortString

public java.lang.String toShortString()
Returns:
a more compact string representation of this shared vertex

IsoSurface Rendering of an AR Representation