|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object vtk.vtkObjectBase vtk.vtkObject vtk.vtkOrderedTriangulator
vtkOrderedTriangulator - helper class to generate triangulations. This class is used to generate unique triangulations of points. The uniqueness of the triangulation is controlled by the id of the inserted points in combination with a Delaunay criterion. The class is designed to be very fast and uses block memory allocations to support rapid triangulation generation. Also, the assumption behind the class is that a maximum of hundreds of points are to be triangulated. If you desire more robust triangulation methods use vtkPolygon::Triangulate(), vtkDelaunay2D, or vtkDelaunay3D. Background: Delaunay triangulations are unique assuming a random distribution of input points. The 3D Delaunay criterion is as follows: the circumsphere of each tetrahedron contains no other points of the triangulation except for the four points defining the tetrahedron. In application this property is hard to satisfy because objects like cubes are defined by eight points all sharing the same circumsphere (center and radius); hence the Delaunay triangulation is not unique. These so-called degenerate situations are typically resolved by arbitrary selecting a triangulation. This code does something different: it resolves degenerate triangulations by modifying the "InCircumsphere" method to use a slightly smaller radius. Hence, degenerate points are always considered "out" of the circumsphere. This, in combination with an ordering (based on id) of the input points, guarantees a unique triangulation. There is another related characteristic of Delaunay triangulations. Given a N-dimensional Delaunay triangulation, points lying on a (N-1) dimensional plane also form a (N-1) Delaunay triangulation. This means for example, that if a 3D cell is defined by a set of (2D) planar faces, then the face triangulations are Delaunay. Combinaing this with the method to generate unique triangulations described previously, the triangulations on the face are guaranteed unique. This fact can be used to triangulate 3D objects in such a way to guarantee compatible face triangulations. This is a very useful fact for parallel processing, or performing operations like clipping that require compatible triangulations across 3D cell faces. (See vtkClipVolume for an example.) A special feature of this class is that it can generate triangulation templates on the fly. If template triangulation is enabled, then the ordered triangulator will first triangulate the cell using the slower ordered Delaunay approach, and then store the result as a template. Later, if the same cell type and cell configuration is encountered, then the template is reused which greatly speeds the triangulation. JavaBean wrapper for vtkOrderedTriangulator object.
vtkDelaunay2D
,
vtkDelaunay3D
,
Serialized FormField Summary | |
protected java.beans.PropertyChangeSupport |
changes
|
Fields inherited from class vtk.vtkObjectBase |
vtkId |
Constructor Summary | |
|
vtkOrderedTriangulator()
|
protected |
vtkOrderedTriangulator(int dmy)
|
Method Summary | |
int |
addTetras(int id0,
vtkCellArray id1)
Add the tetrahedra classified (0=inside,1=outside) to the connectivity list provided. |
int |
addTetras(int id0,
vtkIdList id1,
vtkPoints id2)
Add the tetrahedra classified (0=inside,1=outside) to the list of ids and coordinates provided. |
int |
addTetras(int id0,
vtkUnstructuredGrid id1)
Add the tetras to the unstructured grid provided. |
int |
addTriangles(int id0,
vtkCellArray id1)
Add the triangle faces classified (2=boundary) and attached to the specified point id to the connectivity list provided. |
int |
addTriangles(vtkCellArray id0)
Add the triangle faces classified (2=boundary) to the connectivity list provided. |
java.lang.String |
getClassName()
Return the class name as a string. |
int |
getNextTetra(int id0,
vtkTetra id1,
vtkDataArray id2,
vtkDoubleArray id3)
Methods to get one tetra at a time. |
int |
getPreSorted()
Boolean indicates whether the points have been pre-sorted. |
int |
getTetras(int id0,
vtkUnstructuredGrid id1)
Initialize and add the tetras and points from the triangulation to the unstructured grid provided. |
vtkOrderedTriangulator |
getThisOrderedTriangulator()
|
int |
getUseTemplates()
If this flag is set, then the ordered triangulator will create and use templates for the triangulation. |
int |
getUseTwoSortIds()
Tells the triangulator that a second sort id is provided for each point and should also be considered when sorting. |
void |
initTetraTraversal()
Methods to get one tetra at a time. |
void |
initTriangulation(double[] id0,
int id1)
Initialize the triangulation process. |
void |
initTriangulation(double id0,
double id1,
double id2,
double id3,
double id4,
double id5,
int id6)
Initialize the triangulation process. |
int |
insertPoint(int id0,
double[] id1,
double[] id2,
int id3)
For each point to be inserted, provide an id, a position x, parametric coordinate p, and whether the point is inside (type=0), outside (type=1), or on the boundary (type=2). |
int |
insertPoint(int id0,
int id1,
double[] id2,
double[] id3,
int id4)
For each point to be inserted, provide an id, a position x, parametric coordinate p, and whether the point is inside (type=0), outside (type=1), or on the boundary (type=2). |
int |
insertPoint(int id0,
int id1,
int id2,
double[] id3,
double[] id4,
int id5)
For each point to be inserted, provide an id, a position x, parametric coordinate p, and whether the point is inside (type=0), outside (type=1), or on the boundary (type=2). |
int |
isA(java.lang.String id0)
Return 1 if this class is the same type of (or a subclass of) the named class. |
void |
preSortedOff()
Boolean indicates whether the points have been pre-sorted. |
void |
preSortedOn()
Boolean indicates whether the points have been pre-sorted. |
void |
setPreSorted(int id0)
Boolean indicates whether the points have been pre-sorted. |
void |
setUseTemplates(int id0)
If this flag is set, then the ordered triangulator will create and use templates for the triangulation. |
void |
setUseTwoSortIds(int id0)
Tells the triangulator that a second sort id is provided for each point and should also be considered when sorting. |
void |
templateTriangulate(int id0,
int id1,
int id2)
Perform the triangulation. |
void |
triangulate()
Perform the triangulation. |
void |
updatePointType(int id0,
int id1)
Update the point type. |
void |
useTemplatesOff()
If this flag is set, then the ordered triangulator will create and use templates for the triangulation. |
void |
useTemplatesOn()
If this flag is set, then the ordered triangulator will create and use templates for the triangulation. |
void |
useTwoSortIdsOff()
Tells the triangulator that a second sort id is provided for each point and should also be considered when sorting. |
void |
useTwoSortIdsOn()
Tells the triangulator that a second sort id is provided for each point and should also be considered when sorting. |
protected void |
VTKCastInit()
|
void |
VTKInit()
|
Methods inherited from class vtk.vtkObject |
AddObserver, breakOnError, debugOff, debugOn, getDebug, getGlobalWarningDisplay, getMTime, getThisObject, globalWarningDisplayOff, globalWarningDisplayOn, hasObserver, hasObserver, invokeEvent, invokeEvent, modified, Print, PrintRevisions, register, removeObserver, removeObservers, removeObservers, setDebug, setGlobalWarningDisplay, unRegister |
Methods inherited from class vtk.vtkObjectBase |
addPropertyChangeListener, finalize, getReferenceCount, getThisObjectBase, isTypeOf, removePropertyChangeListener, setReferenceCount, VTKDelete |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.beans.PropertyChangeSupport changes
Constructor Detail |
public vtkOrderedTriangulator()
protected vtkOrderedTriangulator(int dmy)
Method Detail |
public vtkOrderedTriangulator getThisOrderedTriangulator()
public java.lang.String getClassName()
vtkObjectBase
getClassName
in class vtkObject
public int isA(java.lang.String id0)
vtkObjectBase
isA
in class vtkObject
public void initTriangulation(double id0, double id1, double id2, double id3, double id4, double id5, int id6)
public void initTriangulation(double[] id0, int id1)
public int insertPoint(int id0, double[] id1, double[] id2, int id3)
public int insertPoint(int id0, int id1, double[] id2, double[] id3, int id4)
public int insertPoint(int id0, int id1, int id2, double[] id3, double[] id4, int id5)
public void triangulate()
public void templateTriangulate(int id0, int id1, int id2)
public void updatePointType(int id0, int id1)
public void setUseTemplates(int id0)
public int getUseTemplates()
public void useTemplatesOn()
public void useTemplatesOff()
public void setPreSorted(int id0)
public int getPreSorted()
public void preSortedOn()
public void preSortedOff()
public void setUseTwoSortIds(int id0)
public int getUseTwoSortIds()
public void useTwoSortIdsOn()
public void useTwoSortIdsOff()
public int getTetras(int id0, vtkUnstructuredGrid id1)
public int addTetras(int id0, vtkUnstructuredGrid id1)
public int addTetras(int id0, vtkCellArray id1)
public int addTetras(int id0, vtkIdList id1, vtkPoints id2)
public int addTriangles(vtkCellArray id0)
public int addTriangles(int id0, vtkCellArray id1)
public void initTetraTraversal()
public int getNextTetra(int id0, vtkTetra id1, vtkDataArray id2, vtkDoubleArray id3)
public void VTKInit()
VTKInit
in class vtkObject
protected void VTKCastInit()
VTKCastInit
in class vtkObject
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |