Holds options for checker tools. More...
#include <cadex/ModelCheck_BRepChecker.hxx>
Public Types | |
enum | ModeEnum { Coarse , Moderate , Fine } |
Preset options for tools. More... | |
typedef std::shared_ptr< internal::ModelCheck_BRepCheckerOptionsImpl > | ImplType |
Public Member Functions | |
Options () | |
Constructor. | |
bool | LoadFromFile (const Base_String &theFile) |
Loads options from file. | |
Options & | Mode (ModeEnum theMode) |
Sets a preset mode. | |
Options & | Tools (Tool::FlagType theTools) |
Sets which tools will be used by checker. | |
Tool::FlagType | Tools () const |
Returns tools flag. | |
Options & | SurfaceContinuity (ModelCheck_Continuity theSurfaceContinuity) |
Sets target surface continuity for Tool::Continuity. | |
ModelCheck_Continuity | SurfaceContinuity () const |
Returns target surface continuity for Tool::Continuity. | |
Options & | CurveContinuity (ModelCheck_Continuity theCurveContinuity) |
Sets target curve continuity for Tool::Continuity. | |
ModelCheck_Continuity | CurveContinuity () const |
Returns target curve continuity for Tool::Continuity. | |
Options & | OverlapControlPoints (size_t OverlapControlPoints) |
Sets number of control points for Tool::Overlap. | |
size_t | OverlapControlPoints () const |
Returns number of control points for Tool::Overlap. | |
Options & | AllowedOverlap (double theAllowedOverlap) |
Sets allowed overlap for Tool::Overlap. | |
double | AllowedOverlap () const |
Returns allowed overlap for Tool::Overlap. | |
Options & | WireBBoxDiagLength (double WireBBoxDiagLength) |
Sets target wire bounding box diagonal length for Tool::Size. | |
double | WireBBoxDiagLength () const |
Returns target wire bounding box diagonal length for Tool::Size. | |
Options & | EdgeBBoxDiagLength (double EdgeBBoxDiagLength) |
Sets target edge bounding box diagonal length for Tool::Size. | |
double | EdgeBBoxDiagLength () const |
Returns target edge bounding box diagonal length for Tool::Size. | |
Options & | ToleranceControlPoints (size_t ToleranceControlPoints) |
Sets number of control points for Tool::Tolerance. | |
size_t | ToleranceControlPoints () const |
Returns number of control points for Tool::Tolerance. | |
Options & | ToleranceThreshold (double ToleranceThreshold) |
Sets tolerance threshold for Tool::Tolerance. | |
double | ToleranceThreshold () const |
Returns tolerance threshold for Tool::Tolerance. | |
Options & | UseSameParam (bool UseSameParam) |
Sets "use same parameter" flag for Tool::Tolerance. | |
bool | UseSameParam () const |
Returns "use same parameter" flag for Tool::Tolerance. | |
const ImplType & | Impl () const |
Protected Attributes | |
ImplType | myImpl |
Holds options for checker tools.
All setter methods in class return this
object to allow convenient syntax, sometimes called "chaining".
Example:
Preset options for tools.
cadex::ModelCheck_BRepChecker::Options::Options | ( | ) |
Constructor.
By default Tools() is set to Tool::All and Mode() is set to Options::Moderate.
Options & cadex::ModelCheck_BRepChecker::Options::AllowedOverlap | ( | double | theAllowedOverlap | ) |
Sets allowed overlap for Tool::Overlap.
The percent of parametric range of edges, on which they are allowed to overlap. E.g., edge1 has parameters [0, 5] and edge2 has parameters [0, 10]; if allowed overlap is set to 50 and edges overlap from their starts, then the maximum overlap segment length for edge1 is [0, 2.5] and for edge2 is [0, 5].
Options & cadex::ModelCheck_BRepChecker::Options::EdgeBBoxDiagLength | ( | double | theEdgeBBoxDiagLength | ) |
Sets target edge bounding box diagonal length for Tool::Size.
Target length for edge bounding box diagonal. If set to -1 then bounding box is checked to be enough to hold edge's end vertices so their tolerances doesn't overlap each other.
bool cadex::ModelCheck_BRepChecker::Options::LoadFromFile | ( | const Base_String & | theFile | ) |
Loads options from file.
theFile | Path to file to load options from. Must be any .ini with section [CadexBRepChecker]. |
Example:
true
if loading was successful and false
otherwise. Options & cadex::ModelCheck_BRepChecker::Options::OverlapControlPoints | ( | size_t | theOverlapControlPoints | ) |
Sets number of control points for Tool::Overlap.
Number of points along the edges, on which distances will be calculated. More points gives more accurate results, but slows down checking.
Options & cadex::ModelCheck_BRepChecker::Options::ToleranceControlPoints | ( | size_t | theToleranceControlPoints | ) |
Sets number of control points for Tool::Tolerance.
Number of points along the edges, on which distances will be calculated. More points gives more accurate results, but slows down checking.
Options & cadex::ModelCheck_BRepChecker::Options::ToleranceThreshold | ( | double | theToleranceThreshold | ) |
Sets tolerance threshold for Tool::Tolerance.
Target threshold. If set to -1 then shape's tolerance is used as value.
ModelCheck_BRepChecker::Tool::FlagType cadex::ModelCheck_BRepChecker::Options::Tools | ( | ) | const |
Returns tools flag.
By applying bitwise AND one can determine which tools were set in options.
Example:
Options & cadex::ModelCheck_BRepChecker::Options::Tools | ( | Tool::FlagType | theTools | ) |
Sets which tools will be used by checker.
For convenience accepts a bitwise sequence of tools.
Example:
Options & cadex::ModelCheck_BRepChecker::Options::UseSameParam | ( | bool | theUseSameParam | ) |
Sets "use same parameter" flag for Tool::Tolerance.
Determines if tool should trust the "same parameter" flag in edge. If this option is checked and edge has "same parameter" flag, then tolerance checking will be much faster, but the results can be very inaccurate. Alternatively you can use this option to check if edge has correct "same parameter" flag.
Options & cadex::ModelCheck_BRepChecker::Options::WireBBoxDiagLength | ( | double | theWireBBoxDiagLength | ) |
Sets target wire bounding box diagonal length for Tool::Size.
Target length for wire bounding box diagonal. If set to -1 then wires will not be checked.