Open CASCADE Technology 7.8.2.dev
|
The class Check provides a diagnostic tool for checking the validity of the single shape or couple of shapes. The shapes are checked on: More...
#include <BRepAlgoAPI_Check.hxx>
Public Member Functions | |
Constructors | |
BRepAlgoAPI_Check () | |
Empty constructor. | |
virtual | ~BRepAlgoAPI_Check () |
Empty constructor. | |
BRepAlgoAPI_Check (const TopoDS_Shape &theS, const Standard_Boolean bTestSE=Standard_True, const Standard_Boolean bTestSI=Standard_True, const Message_ProgressRange &theRange=Message_ProgressRange()) | |
Constructor for checking single shape. | |
BRepAlgoAPI_Check (const TopoDS_Shape &theS1, const TopoDS_Shape &theS2, const BOPAlgo_Operation theOp=BOPAlgo_UNKNOWN, const Standard_Boolean bTestSE=Standard_True, const Standard_Boolean bTestSI=Standard_True, const Message_ProgressRange &theRange=Message_ProgressRange()) | |
Constructor for checking the couple of shapes. Additionally to the validity checks of each given shape, the types of the given shapes will be checked on validity for Boolean operation of given type. | |
Initializing the algorithm | |
void | SetData (const TopoDS_Shape &theS, const Standard_Boolean bTestSE=Standard_True, const Standard_Boolean bTestSI=Standard_True) |
Initializes the algorithm with single shape. | |
void | SetData (const TopoDS_Shape &theS1, const TopoDS_Shape &theS2, const BOPAlgo_Operation theOp=BOPAlgo_UNKNOWN, const Standard_Boolean bTestSE=Standard_True, const Standard_Boolean bTestSI=Standard_True) |
Initializes the algorithm with couple of shapes. Additionally to the validity checks of each given shape, the types of the given shapes will be checked on validity for Boolean operation of given type. | |
Performing the operation | |
void | Perform (const Message_ProgressRange &theRange=Message_ProgressRange()) |
Performs the check. | |
Getting the results. | |
Standard_Boolean | IsValid () |
Shows whether shape(s) valid or not. | |
const BOPAlgo_ListOfCheckResult & | Result () |
Returns faulty shapes. | |
Public Member Functions inherited from BOPAlgo_Options | |
BOPAlgo_Options () | |
Empty constructor. | |
BOPAlgo_Options (const Handle< NCollection_BaseAllocator > &theAllocator) | |
Constructor with allocator. | |
virtual | ~BOPAlgo_Options () |
Destructor. | |
const Handle< NCollection_BaseAllocator > & | Allocator () const |
Returns allocator. | |
virtual void | Clear () |
Clears all warnings and errors, and any data cached by the algorithm. User defined options are not cleared. | |
void | AddError (const Handle< Message_Alert > &theAlert) |
Adds the alert as error (fail) | |
void | AddWarning (const Handle< Message_Alert > &theAlert) |
Adds the alert as warning. | |
Standard_Boolean | HasErrors () const |
Returns true if algorithm has failed. | |
Standard_Boolean | HasError (const Handle< Standard_Type > &theType) const |
Returns true if algorithm has generated error of specified type. | |
Standard_Boolean | HasWarnings () const |
Returns true if algorithm has generated some warning alerts. | |
Standard_Boolean | HasWarning (const Handle< Standard_Type > &theType) const |
Returns true if algorithm has generated warning of specified type. | |
const Handle< Message_Report > & | GetReport () const |
Returns report collecting all errors and warnings. | |
void | DumpErrors (Standard_OStream &theOS) const |
Dumps the error status into the given stream. | |
void | DumpWarnings (Standard_OStream &theOS) const |
Dumps the warning statuses into the given stream. | |
void | ClearWarnings () |
Clears the warnings of the algorithm. | |
void | SetFuzzyValue (const Standard_Real theFuzz) |
Sets the additional tolerance. | |
Standard_Real | FuzzyValue () const |
Returns the additional tolerance. | |
void | SetUseOBB (const Standard_Boolean theUseOBB) |
Enables/Disables the usage of OBB. | |
Standard_Boolean | UseOBB () const |
Returns the flag defining usage of OBB. | |
void | SetRunParallel (const Standard_Boolean theFlag) |
Set the flag of parallel processing if <theFlag> is true the parallel processing is switched on if <theFlag> is false the parallel processing is switched off. | |
Standard_Boolean | RunParallel () const |
Returns the flag of parallel processing. | |
Protected Attributes | |
Fields | |
TopoDS_Shape | myS1 |
The first shape. | |
TopoDS_Shape | myS2 |
The second shape. | |
Standard_Boolean | myTestSE |
Flag defining whether to look for small edges in the given shapes or not. | |
Standard_Boolean | myTestSI |
Flag defining whether to check the input edges on self-interference or not. | |
BOPAlgo_Operation | myOperation |
Type of Boolean operation for which the validity of input shapes should be checked. | |
BOPAlgo_ListOfCheckResult | myFaultyShapes |
Found faulty shapes. | |
Protected Attributes inherited from BOPAlgo_Options | |
Handle< NCollection_BaseAllocator > | myAllocator |
Enables/Disables the usage of OBB. | |
Handle< Message_Report > | myReport |
Enables/Disables the usage of OBB. | |
Standard_Boolean | myRunParallel |
Enables/Disables the usage of OBB. | |
Standard_Real | myFuzzyValue |
Enables/Disables the usage of OBB. | |
Standard_Boolean | myUseOBB |
Enables/Disables the usage of OBB. | |
Additional Inherited Members | |
Static Public Member Functions inherited from BOPAlgo_Options | |
static Standard_Boolean | GetParallelMode () |
Gets the global parallel mode. | |
static void | SetParallelMode (const Standard_Boolean theNewMode) |
Sets the global parallel mode. | |
Protected Member Functions inherited from BOPAlgo_Options | |
Standard_Boolean | UserBreak (const Message_ProgressScope &thePS) |
Adds error to the report if the break signal was caught. Returns true in this case, false otherwise. | |
The class Check provides a diagnostic tool for checking the validity of the single shape or couple of shapes. The shapes are checked on:
The class provides two ways of checking shape(-s)
BRepAlgoAPI_Check::BRepAlgoAPI_Check | ( | ) |
Empty constructor.
|
virtual |
Empty constructor.
BRepAlgoAPI_Check::BRepAlgoAPI_Check | ( | const TopoDS_Shape & | theS, |
const Standard_Boolean | bTestSE = Standard_True, | ||
const Standard_Boolean | bTestSI = Standard_True, | ||
const Message_ProgressRange & | theRange = Message_ProgressRange() ) |
Constructor for checking single shape.
theS | [in] - the shape to check; |
bTestSE | [in] - flag which specifies whether to check the shape on small edges or not; by default it is set to TRUE; |
bTestSI | [in] - flag which specifies whether to check the shape on self-interference or not; by default it is set to TRUE; |
theRange | [in] - parameter to use progress indicator |
BRepAlgoAPI_Check::BRepAlgoAPI_Check | ( | const TopoDS_Shape & | theS1, |
const TopoDS_Shape & | theS2, | ||
const BOPAlgo_Operation | theOp = BOPAlgo_UNKNOWN, | ||
const Standard_Boolean | bTestSE = Standard_True, | ||
const Standard_Boolean | bTestSI = Standard_True, | ||
const Message_ProgressRange & | theRange = Message_ProgressRange() ) |
Constructor for checking the couple of shapes. Additionally to the validity checks of each given shape, the types of the given shapes will be checked on validity for Boolean operation of given type.
theS1 | [in] - the first shape to check; |
theS2 | [in] - the second shape to check; |
theOp | [in] - the type of Boolean Operation for which the validity of given shapes should be checked. |
bTestSE | [in] - flag which specifies whether to check the shape on small edges or not; by default it is set to TRUE; |
bTestSI | [in] - flag which specifies whether to check the shape on self-interference or not; by default it is set to TRUE; |
theRange | [in] - parameter to use progress indicator |
|
inline |
Shows whether shape(s) valid or not.
void BRepAlgoAPI_Check::Perform | ( | const Message_ProgressRange & | theRange = Message_ProgressRange() | ) |
Performs the check.
|
inline |
Returns faulty shapes.
|
inline |
Initializes the algorithm with single shape.
theS | [in] - the shape to check; |
bTestSE | [in] - flag which specifies whether to check the shape on small edges or not; by default it is set to TRUE; |
bTestSI | [in] - flag which specifies whether to check the shape on self-interference or not; by default it is set to TRUE; |
|
inline |
Initializes the algorithm with couple of shapes. Additionally to the validity checks of each given shape, the types of the given shapes will be checked on validity for Boolean operation of given type.
theS1 | [in] - the first shape to check; |
theS2 | [in] - the second shape to check; |
theOp | [in] - the type of Boolean Operation for which the validity of given shapes should be checked. |
bTestSE | [in] - flag which specifies whether to check the shape on small edges or not; by default it is set to TRUE; |
bTestSI | [in] - flag which specifies whether to check the shape on self-interference or not; by default it is set to TRUE; |
|
protected |
Found faulty shapes.
|
protected |
Type of Boolean operation for which the validity of input shapes should be checked.
|
protected |
The first shape.
|
protected |
The second shape.
|
protected |
Flag defining whether to look for small edges in the given shapes or not.
|
protected |
Flag defining whether to check the input edges on self-interference or not.