Defines parameters used by the mesh generator. More...
Public Types | |
| enum | GranularityType { Coarse , Medium , Fine , Custom } |
| Defines target accuracy of the mesh to be generated. More... | |
Public Member Functions | |
| MeshGeneratorParameters (global::System.IntPtr cPtr, bool cMemoryOwn) | |
| MeshGeneratorParameters () | |
| Constructor. | |
| MeshGeneratorParameters (cadex.ModelAlgo.MeshGeneratorParameters.GranularityType theGranularity) | |
| Constructor. | |
| cadex.ModelAlgo.MeshGeneratorParameters.GranularityType | Granularity () |
| Returns a granularity value. | |
| void | SetGranularity (cadex.ModelAlgo.MeshGeneratorParameters.GranularityType theGranularity) |
| double | ChordalDeflection () |
| Returns chordal deflection. | |
| void | SetChordalDeflection (double theValue) |
| Sets chordal deflection. | |
| bool | IsRelativeChordalDeflection () |
| Returns whether ChordalDeflection() contains an absolute or relative value. | |
| void | SetIsRelativeChordalDeflection (bool theValue) |
| Sets whether ChordalDeflection() contains an absolute or relative value. | |
| double | AngularDeflection () |
| Returns angular deflection. | |
| void | SetAngularDeflection (double theValue) |
| Sets angular deflection. | |
Public Member Functions inherited from cadex.BaseObject | |
| BaseObject (global::System.IntPtr cPtr, bool cMemoryOwn) | |
| void | Dispose () |
| bool | IsNull () |
| ulong | Id () |
| Return unique identifier of public object. | |
| bool | IsEqual (cadex.BaseObject theObj) |
| override int | GetHashCode () |
| override bool | Equals (System.Object o) |
Static Public Member Functions | |
| static cadex.ModelAlgo.MeshGeneratorParameters | Cast (cadex.BaseObject theBase) |
Protected Member Functions | |
| override void | Dispose (bool disposing) |
Defines parameters used by the mesh generator.
Parameters can be set to and retrieved from the mesh generator using MeshGenerator.SetParameters() and MeshGenerator.Parameters() methods respectively.
Defines target accuracy of the mesh to be generated.
Provides predefined values for chordal and angular deflections:
| Fine | Medium | Coarse | |
|---|---|---|---|
| chordal deflection | 0.004 (0.4%) | 0.01 (1%) | 0.05 (5%) |
| angular deflection | 20 degrees | 45 degrees | 60 degrees |
The predefined values are applied when invoking MeshGeneratorParameters.SetGranularity().
Chordal and angular deflections can also be set to explicitly specified values using MeshGeneratorParameters.SetChordalDeflection() and MeshGeneratorParameters.SetAngularDeflection() methods.
|
inline |
Constructor.
Sets default parameter values according to GranularityType.Fine.
|
inline |
|
inline |
Returns angular deflection.
|
inline |
Returns chordal deflection.
Returns a relative or absolute value of the chordal deflection depending on the value returned by IsRelativeChordalDeflection().
Default value is 0.004 (0.4%) when IsRelativeChordalDeflection() is true.
|
inlineprotectedvirtual |
Reimplemented from cadex.BaseObject.
|
inline |
Returns a granularity value.
|
inline |
Returns whether ChordalDeflection() contains an absolute or relative value.
By default, it is true.
|
inline |
Sets angular deflection.
Specifies a maximum deviation (in radians) between tangents at two adjacent mesh nodes when tessellating an edge curve or between normals when tessellating a face surface.
Default value in radians is equal to 20 degrees.
Sets granularity to Custom.
|
inline |
Sets chordal deflection.
Specifies either a value relative to the body bounding box (if IsRelativeChordalDeflection() is true) or an absolute value of the maximum deflection of the visualization mesh.
Chordal deflection is basically a deviation of the triangles from the original surfaces or curves. Default value is 0.004 (0.4%) when IsRelativeChordalDeflection() is true.
Note that in some cases the algorithm can produce more coarse triangulation.
Sets granularity to Custom.
|
inline |
If theGranularity is Custom, the method does nothing.
Otherwise sets chordal and angular deflections according to the specified granularity value. Refer to the table in the description of the GranularityType. IsRelativeChordalDeflection() is set to true.
|
inline |
Sets whether ChordalDeflection() contains an absolute or relative value.
Specifies whether ChordalDeflection() contains an absolute (if false) or a relative to the shape bounding box (if true, by default) value of the deflection.
Sets granularity to Custom.