public class RemoveDuplicateInfo extends Object
PointSet
and its sub-classes.
The idea is to find data elements which are close in value to each other and merge them into a single instance, then change the indexing of the edges and faces to reflect these changes.
Modifier and Type | Field and Description |
---|---|
static Attribute[] |
defaultAttrs
read out the attributes, which are given by the user,
to be compared for equality.
|
Modifier and Type | Method and Description |
---|---|
double |
getEps()
get Tolerance for equality
|
int[] |
getReferenceTable() |
static void |
removeCycleDefinition(int[][] faces)
a face definition can repeat the first index at the end
excample: {1,2,3,4,1} or {1,2,3,4}
in first case: the last index will be removed
|
static PointSet |
removeDuplicateVertices(PointSet ps,
Attribute... attributes)
merges vertices which appears more than once in the geometry
the result of type PointSet is especialy the same typ as the given geometry
|
static PointSet |
removeDuplicateVertices(PointSet ps,
double eps,
Attribute... attributes)
merges vertices which appears more than once in the geometry
the result of type PointSet is especialy the same typ as the given geometry
|
static double[][] |
removeNoFaceVertices(double[][] vertices,
int[][] faces)
removes vertices which are not used by faces.
|
void |
setEps(double eps)
set Tolerance for equality
|
static void |
simplifySceneTree(SceneGraphComponent g)
simplifys the SceneGraphComponent tree recursivly
Nodes with cameras, geometrys and lights will not be changed
Nodes with transformations and Appearances will only be deleted if no
geometry, camera or light will be effected.
|
public static final Attribute[] defaultAttrs
public static PointSet removeDuplicateVertices(PointSet ps, Attribute... attributes)
public static PointSet removeDuplicateVertices(PointSet ps, double eps, Attribute... attributes)
public double getEps()
public void setEps(double eps)
public int[] getReferenceTable()
public static double[][] removeNoFaceVertices(double[][] vertices, int[][] faces)
vertices
- faces
- public static void removeCycleDefinition(int[][] faces)
public static void simplifySceneTree(SceneGraphComponent g)