Builds triangular mesh for the shape\n\
usage: incmesh Shape LinearDeflection [options]\n\
options:\n\
- -a val angular deflection in deg (default ~28.64 deg = 0.5 rad)\n\
+ -a val angular deflection in deg\n\
+ (default ~28.64 deg = 0.5 rad)\n\n\
+ -min minimum size parameter limiting size of triangle's\n\
+ edges to prevent sinking into amplification in case\n\
+ of distorted curves and surfaces\n\n\
-relative notifies that relative deflection is used\n\
- (switched off by default)\n\
+ (switched off by default)\n\n\
-int_vert_off disables insertion of internal vertices into mesh\n\
(enabled by default)\n\
-parallel enables parallel execution (switched off by default)\n";
Standard_Real aLinDeflection = Max(Draw::Atof(argv[2]), Precision::Confusion());
Standard_Real aAngDeflection = 0.5;
+ Standard_Real aMinSize = Precision::Confusion();
Standard_Boolean isRelative = Standard_False;
Standard_Boolean isInParallel = Standard_False;
Standard_Boolean isIntVertices = Standard_True;
Standard_Real aVal = Draw::Atof(argv[i++]);
if (aOpt == "-a")
aAngDeflection = aVal * M_PI / 180.;
+ else if (aOpt == "-min")
+ aMinSize = aVal;
else
--i;
}
<< (isInParallel ? "ON" : "OFF") << "\n";
BRepMesh_IncrementalMesh aMesher;
- aMesher.SetShape (aShape);
- aMesher.SetDeflection (aLinDeflection);
- aMesher.SetRelative (isRelative);
- aMesher.SetAngle (aAngDeflection);
- aMesher.SetParallel (isInParallel);
+ aMesher.SetShape (aShape);
+ aMesher.SetDeflection(aLinDeflection);
+ aMesher.SetRelative (isRelative);
+ aMesher.SetAngle (aAngDeflection);
+ aMesher.SetParallel (isInParallel);
+ aMesher.SetMinSize (aMinSize);
aMesher.SetInternalVerticesMode(isIntVertices);
aMesher.Perform();