|
EdgeLinesFactory Class |
EdgeLinesFactory can generated edge lines where the angle between two adjacent triangles is bigger then the specified angle.
Inheritance Hierarchy Namespace: Ab3d.UtilitiesAssembly: Ab3d.PowerToys (in Ab3d.PowerToys.dll) Version: 11.2.9104.2045
Syntax public class EdgeLinesFactory
The EdgeLinesFactory type exposes the following members.
Constructors Properties | Name | Description |
---|
| AddMeshOuterEdges |
When true (by default) then edge lines are generated for edges that do not have any adjacent triangle and define the mesh outer edge.
|
| CacheIntermediateObjects |
When true (by default) then intermediate objects that are required for edge lines generation are preserved from processing of the previous meshes.
This reduces the memory requirements and number of garbage collections.
|
| DuplicatePositionsPrecisionBitsCount |
Gets or sets number of bits in the uint value that are used to hash the positions when the code combines duplicate positions.
When combining duplicate positions, the double x, y and z values are normalized to values from 0 to 1 based the bounding box of the positions.
Then the normalized value is multiplied by a factor that is generated from this value (for example for the default 22 bits the value 0x3FFFFF is generated).
This value is then used to calculate the hash of the positions. The reason why not all bits are used (32) is that this helps combine positions
that should be on the same 3D space, but are slightly different because of floating point imprecision (for example when using Boolean operations or Slice).
Smaller number helps combine similar positions. Max value is 31 bits.
|
| ProcessDuplicatePositions |
When true (by default) then the mesh is first processed so that all duplicate positions (positions that have same x, y and z coordinates) are combined.
Duplicate positions are very common because they are required to create sharp edges by defining different normals for each position.
If you are sure that your mesh does not have duplicate positions, then you can set ProcessDuplicatePositions to false
to significantly improve the performance of edge generation.
|
| ProcessPartiallyCoveredEdges |
When true (by default) then the EdgeLinesFactory executes an algorithm to processes meshes that have triangle with edges
that may have multiple connected triangles that fully or only partially covert the triangle edges.
If you are sure that the mesh have nicely defined triangles where each triangle edge is fully covered by any adjacent triangle edge (except on the outer mesh borders),
then you can set ProcessPartiallyCoveredEdges to false to significantly improve the performance of edge generation.
|
TopMethods | Name | Description |
---|
| AddEdgeLinePositions |
AddEdgeLinePositions method goes through all GeometryModel3D objects in the specified model3D hierarchy and
collects the edge lines and adds their start and end positions to the linePositions collection.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
| AddEdgeLines |
AddEdgeLinePositions method goes through all GeometryModel3D objects in the specified model3D hierarchy and
collects the edge lines and adds their start and end positions to the linePositions collection.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
| ClearEdgeLineIndices |
ClearEdgeLineIndices method clears the EdgeLineIndicesProperty and EdgeMultiLineVisual3DProperty DependencyProperty values in the specified model3D and all its children.
|
| CreateEdgeLinesForEachGeometryModel3D |
CreateEdgeLinesForEachGeometryModel3D method goes through all GeometryModel3D objects in the specified model3D hierarchy and
creates one MultiLineVisual3D for each GeometryModel3D.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
| GenerateEdgeLineIndices |
GenerateEdgeLineIndices method goes through all GeometryModel3D objects in the specified model3D hierarchy and for each MeshGeometry3D
sets the EdgeLineIndicesProperty DependencyProperty to the list of edge lines that is created by this method.
|
| GetEdgeLineIndices |
GetEdgeLineIndices method returns list of positions indices that define the edge lines for the specified meshGeometry3D and edgeStartAngleInDegrees.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
| GetEdgeLines |
GetEdgeLines method returns a Point3DCollection with edge line position.
The method goes through all GeometryModel3D objects in the specified model3D hierarchy and
collects the edge lines and adds their start and end positions to the linePositions collection.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
| SetEdgeLinesForEachGeometryModel3D |
CreateEdgeLinesForEachGeometryModel3D method goes through all GeometryModel3D objects in the specified model3D hierarchy and
creates one MultiLineVisual3D for each GeometryModel3D.
The edge lines are created if angle in degrees between two adjacent triangles is bigger then the specified edgeStartAngleInDegrees, then an edge line is created between triangles.
|
TopFields | Name | Description |
---|
| EdgeMultiLineVisual3DProperty |
EdgeMultiLineVisual3DProperty is a DependencyProperty that can be set to the GeometryModel3D object and specifies a MultiLineVisual3D object that is used to show edge lines.
|
TopSee Also