- 04 Oct, 2017 1 commit
-
-
emv authored
Boolean Operations: 1. Face/Face intersection post treatment - Unify vertices put on the section curves, which were rejected as existing ones, with the vertices of edges by which these section curves have been rejected. 2. Extend Warnings Reporting system of Boolean operations with the new warnings: - BOPAlgo_AlertIntersectionOfPairOfShapesFailed - to be added when the intersection of pair of sub-shapes of the arguments has failed; - BOPAlgo_AlertBuildingPCurveFailed - to be added when the building of the 2D curve of the edge on face has failed; - BOPAlgo_AlertAcquiredSelfIntersection - to be added when the positioning and tolerances of the arguments leads to creation of self-interfered shapes. These new warnings allow completing the operation even if intersection of some of the sub-shapes or building of some of the PCurves has failed. Moreover, they allow getting the pairs of sub-shapes on which the intersection/projection has failed, providing the user ability to analyze the intersection results. Note that if some of these warnings appear, the result of the operation should be carefully analyzed for validity. 3. Print messages for the Warnings/Errors met during checking of the shape on self-intersection ("bopcheck" command).
-
- 06 Jul, 2017 1 commit
-
-
emv authored
0. Basic tools for defining classes representing alerts (errors, warnings etc.) and collecting them during execution of algorithms are added in Message package. 1. Refactoring of the Error/Warning reporting system of the algorithms in Boolean Component. To dump the description of the Error/Warning status of the algorithm the DumpErrors/DumpWarnings method should be called. Also, the methods GerErrorMsg(int Error) and GetWarningMsg(int Warning) have been implemented to get the description for the given Error/Warning. All Error/Warning statuses are now listed in the enumeration ErrorStatusEnum/WarningStatusEnum of the algorithm. It is also possible to get the shapes for which the warning has been set by using the method GetWarningShapes(). 2. The new class BOPAlgo_Options has been created to unify the options of the BOPAlgo_* and BRepAlgoAPI* algorithms. 3. The new checks across the algorithms have been added to detect and report errors and warnings. 4. Test cases boolean bopcut_complex B9 E1 E5 E8 boolean bopfuse_complex B4 B5 C9 D1 D4 D5 D6 D7 have been rewritten to use Cells Builder algorithm instead of Boolean Operations algorithm, because latter always returns error "Unsupported Boolean operation" for these cases. 5. New chapter has been added in the user guide for Boolean Operations - Error / Warning reporting system. 6. Added comment to NCollection_List::Remove(Iterator&)
-
- 09 Jun, 2017 1 commit
-
-
emv authored
The methods PerformVerticesEE() and PerformVerticesEF() of the class BOPAlgo_PaveFiller have been replaced with the new PerformNewVertices() method. While splitting the Pave Blocks with extra paves, check that the new Pave Blocks have the valid intersection range. If the new Pave Block does not have such range do not create it and unify its vertices making SD vertex. Re-computation of the Shrunk Data for the modified Pave Blocks. The new method BOPDS_DS::IsValidShrunkData(const Handle(BOPDS_PaveBlock)& thePB) has been implemented to check that the Shrunk Data of the Pave Block is still valid. It may become invalid in case the tolerance values of the vertices of the Pave Block have been modified. The test case bugs/modalg_6/bug27448_2 has been marked as BAD, because it uses the invalid shapes as inputs for BOP. Test cases for the issue 0028690.
-
- 05 May, 2017 1 commit
-
-
emv authored
Avoid creation of the small section edges in the Boolean Operations algorithm.
-
- 12 Apr, 2017 1 commit
-
-
emv authored
The Face/Face intersection procedure has been changed in Boolean Operations algorithm. Previously, the intersection tolerance for all section curves between pair of faces has been calculated as the maximal tolerance among all curves. Now, each curve has its own valid tolerance calculated as the maximal deviation of the 3D curve from its 2D curves on faces or surfaces in case there are no 2D curves. Thus, such methods of IntTools_FaceFace algorithm as TolReached3d(), TolReal() and TolReached2d() have been removed. Now the tolerances of the curve can be obtained from the curve itself (IntTools_Curve - result of intersection): - IntTools_Curve::Tolerance() - returns the valid tolerance for the curve; - IntTools_Curve::TangentialTolerance() - returns the tangential tolerance, which depends on the size of the common between faces. Currently, this tolerance is computed for Plane/Plane cases only. For other case, the value of the tangential tolerance is the maximal tolerance of faces. 2D intersection tolerance (IntTools_FaceFace::TolReached2d()) has been completely removed from the algorithm as unused.
-
- 16 Mar, 2017 1 commit
-
-
emv authored
1. Exception in intersection of two analytical faces has been fixed by adding a simple check on number of vertices in the resulting analytical curve; 2. Projection of the Circle on the Cone now checks if the Circle's normal direction is parallel to the Cone direction. If it is not, the different, more advanced, algorithm will be used for projection - ProjLib_ComputeApprox; 3. Intersection of the Edge with the Face (IntTools_EdgeFace algorithm) in QuickCoincidenceCheck mode has been fixed to avoid the checking of the type of the intersection result if the coincidence check gives the positive result; 4. All common IN edges of the intersecting faces has been added for intersection with section edges to avoid self-intersection in the result; 5. Post treatment of the section edges in Boolean operations has been improved with the new stage which treats the possible common zones, not detected by the intersection algorithm, between faces by intersecting each section edge with all faces, not participated in its creation, and in case of coincidence putting it as IN edge into FaceInfo structure of the face. The new function has been implemented for that - BOPAlgo_PaveFiller::PutSEInOtherFaces(). 6. Checking for the SameDomain splits of faces in Boolean Operations has been modified to process the pairs of faces in which both the section curves and common zones are present. 7. Adjustment of the test case boolean gdml_private ZH3 as improvement. 8. Test cases for the issue. 9. Test cases for the parent issue - 0026789.
-
- 26 Jan, 2017 1 commit
-
-
emv authored
0028284: Avoid classification of sub-shapes of arguments of BOPs relatively solids during Intersection phase 1. The methods PerformVZ, PerformEZ, PerformFZ and PerformZZ have been transferred from BOPAlgo_PaveFiller to BOPAlgo_CheckerSI class to perform intersection of sub-shapes with solids only in self-intersection mode. 2. The checks for solids built from the same (shared) faces have been added into methods building the result of Boolean operations - BOPAlgo_BOP::BuildRC() and BOPAlgo_BOP::BuildSolid(). 3. Since the NonDestructive mode is now natively supported by the BOPAlgo_PaveFiller the methods providing the support of this mode by CheckerSI (BOPAlgo_CheckerSI::PrepareCopy() and BOPAlgo_CheckerSI::PostTreatCopy()) are not needed and have been removed. 4. The pairs of sub-shapes with interfering bounding boxes are now sorted before real intersection to guarantee the constant order of intersection of sub-shapes and produce more stable result. The class BOPDS_PassKey has been replaced with simpler class BOPDS_Pair. 5. The class BOPDS_SubIterator has been refactored. 6. Test cases for the issue. 7. Adjustment of the test case boolean volumemaker D2.
-
- 29 Dec, 2016 1 commit
-
-
msv authored
BOPAlgo_CheckerSI crashed due to building of pcurve for an edge not lying on surface. The fix avoids building of pcurves in this algorithm. The new flag has been added in BOPAlgo_PaveFiller class (method SetAvoidBuildPCurve). It tells whether to avoid building pcurves. It is worth to set if the result is not used to create splits of faces, as in example with BOPAlgo_CheckerSI.
-
- 16 Dec, 2016 1 commit
-
-
msv authored
Several improvements have been made in BO code to fix the bug: - Create empty edge-edge interference if intersection is close to an end vertex. This will help to avoid creation of unnecessary edge-face intersections. - Improve PutPaveOnCurve() method to join nearly located vertices when they are put on the same section curve. - Add processing of same-domain vertices for section edges in UpdatePaveBlocks() method. - Improve the method CorrectWires() in order to not increase vertex tolerance if it will cover the major part of an edge. - Replace vertices of section edges by same-domain equivalents. - In the algorithm BOPAlgo_WireSplitter, correct angles computation and evaluation, taking into account periodicity. - Modify PostTreatFF to properly take into account the orientations of coinciding section edges. - In IntTools_Context::ComputePE, check distance from the point to vertices of the edge if the projection to the curve is failure. Tests update: - test offset\faces_type_i\C9 has been updated; now instead of returning bad shape it returns null result. Notes for porting: - Modify BopAlgo_PaveFiller so that on output each interference refers to the new vertex that will hit in the result (same-domain of the initial new vertex). - Make the method BOPDS_DS::Index() returning valid index for new shapes. // eliminate compile warning on VC14
-
- 08 Dec, 2016 2 commits
-
-
emv authored
1. Unification of the usage of the BRepAdaptor_Surface in Boolean Operations algorithm. For each face when it is necessary the Adaptor is initialized only once and stored in Context. For that purpose the new IntTools_Context::SurfaceAdaptor(const TopoDS_Face&) method has been implemented. To provide possibility to take the Adaptor from the context, the context has been added as a parameter in following methods: BOPTools_AlgoTools::MakePCurve() BOPTools_AlgoTools::Sence() BOPTools_AlgoTools2D::BuildPCurveForEdgeOnFace() BOPTools_AlgoTools2D::PointOnSurface BOPTools_AlgoTools2D::CurveOnSurface BOPTools_AlgoTools2D::AdjustPCurveOnFace BOPTools_AlgoTools2D::Make2D BOPTools_AlgoTools2D::MakePCurveOnFace BOPTools_AlgoTools3D::GetNormalToFaceOnEdge It is also possible now to pass the context into BOPAlgo_WireSplitter algorithm. Also, the new IntTools_Context::UVBounds(const TopoDS_Face&) method has been implemented to get the UV bounds of a face. 2. Additional improvement is a calculation of reduced intersection range only for the intersection type VERTEX during computation of Edge/Face interference. 3. The methods IntTools_EdgeFace::Prepare() and IntTools_EdgeFace::FindProjectableRoot() and the fields IntTools_EdgeFace::myProjectableRanges and IntTools_EdgeFace::myFClass2d have been removed as obsolete. 4. Test cases for the issue.
-
emv authored
The Gluing operation is an additional option for the algorithms in the Boolean Component such as General Fuse, Boolean operations, Section operation, Maker Volume and Cells Builder algorithms. The Gluing options have been designed to speed up the computation of the interference among arguments of the operations on special cases, in which the arguments may be overlapping but do not have real intersections between their sub-shapes. This option cannot be used on the shapes having real intersections, like intersection vertex between edges, or intersection vertex between edge and a face or intersection line between faces. The Gluing option is an enumeration implemented in BOPAlgo_GlueEnum.hxx. There are following items in the enum: * BOPAlgo_GlueOff - default value for the algorithms, Gluing is switched off; * BOPAlgo_GlueShift - Glue option for shapes with partial coincidence; * BOPAlgo_GlueFull - Glue option for shapes with full coincidence. For setting the Gluing options for the algorithm it is just necessary to call the SetGlue(BOPAlgo_GlueEnum) method with appropriate Glue value. For using this option in DRAW the command bglue has been implemented: * 0 - default value, Gluing is off; * 1 - for partial coincidence; * 2 - for full coincidence Elimination of the warnings.
-
- 08 Nov, 2016 1 commit
-
-
msv authored
When fuzzy option is in force prevent increasing tolerance of input shapes. Instead pass increased by fuzzy value the tolerances of sub-shapes everywhere where it is needed by intersection algorithms. The following changes in API have been made: - The methods SetFuzzyValue and FuzzyValue have been moved from the classes BOPAlgo_ArgumentAnalyzer, BOPAlgo_Builder, and BOPAlgo_PaveFiller to the base class BOPAlgo_Algo. - The public method BOPDS_DS::VerticesOnIn has been renamed to SubShapesOnIn, and the new output parameter theCommonPB has been added. - In BOPTools_AlgoTools, a new argument "theFuzzyValue" has been added in the methods ComputeVV and AreFacesSameDomain. - In IntTools_Context, a new argument "theFuzzyValue" has been added in the methods ComputeVE and ComputeVF. - The methods SetFuzzyValue and FuzzyValue have been added in the classes IntTools_EdgeEdge, IntTools_FaceFace. - In the class IntTools_EdgeFace, the methods SetTolE, SetTolF, TolE, TolF have been removed, and the methods SetFuzzyValue, FuzzyValue have been added. - The new argument "theTol" has been added in the method IntTools_WLineTool::DecompositionOfWLine. Some improvements in algorithms have been made during fighting with regressions: - Correct initialization of pave blocks for degenerated edges. - In BOPAlgo_PaveFiller::MakeBlocks(), filter out paves on intersection curve that were put on the curve accidentally due to wide range of E-F intersection vertex. - In the method IntTools_Tools::ComputeTolerance the margin added to the computed tolerance has been increased up to 0.001%. - The method BOPAlgo_PaveFiller::PutPaveOnCurve has been corrected in order to use the original vertex tolerance instead of the value increased during putting it on other curves. - The new method BOPDS_PaveBlock::RemoveExtPave has been added. - The vertex tolerance computation in BOPTools_AlgoTools::CorrectCurveOnSurface has been improved, taking into account intersection segments between p-curves (to avoid regression on "bugs modalg_6 bug22794"). - Improve IsExistingPaveBlock to make more stable catching of coincidence of common block with section curve (against regression "bugs modalg_4 bug697_2" on Linux). Test case for the bug has been added. The following test cases have been updated as improvements: boolean gdml_private ZH2 ZI7 ZJ7 boolean volumemaker C4 The test case bugs/modalg_4/pro19653 has been corrected to make it stable. See comment inside the script for details. The test case bugs/modalg_6/bug25880 has been corrected to suppress wrong bfuse commands. The test bugs/modalg_6/bug26954_3 has been corrected to compare the result with more precise reference value. The "faulty" TODO in boolean/volumemaker/A8 has been made actual for Linux as well. //Eliminate compilation error on Linux.
-
- 28 Jul, 2016 1 commit
-
-
emv authored
1. IntTools_ShrunkRange::Perform The algorithm of building shrunk range on the edge has been redesigned to make this range as big as possible. By new definition it has to have the length not less than Precision::Confusion(). Although, the possibility of splitting of the edge has been taken into account. If it is impossible to put vertex on edge in such a way that the tolerance spheres of the edge's vertices do not intersect the tolerance sphere of the putting vertex the edge cannot be split. This possibility is saved in the new field IntTools_ShrunkRange::myIsSplittable. It can be checked by the corresponding method IntTools_ShrunkRange::IsSplittable(). It returns TRUE if the shrunk range is computed successfully and it has the length more than the value of sum of two tolerance values of the edge (for putting vertex, as its tolerance should not be less than the tolerance value of edge) and two Precision::Confusion() values (to make two new edges valid by Shape validity criteria). IntTools_ShrunkRange::myErrorStatus and IntTools_ShrunkRange::ErrorStatus() have been replaced by the IntTools_ShrunkRange::myIsDone and IntTools_ShrunkRange::IsDone(). IntTools_ShrunkRange::IsDone() returns TRUE if the shrunk range has been computed and it has length more than Precision::Confusion(). All computations of the parameters are performed using the GCPnts_AbscissaPoint, but if AbscissaPoint is unable to compute the parameters the Resolution of the curve is used. 2. Boolean Operations algorithm now partially works with the edges that cannot be split or does not have the ShrunkData at all (previously such edges have been considered as micro and just ignored). If by the result of some intersection such edges should be split, i.e. the intersection vertex should be created, the algorithm just ignores them and no vertex is created. But if such edges coincide with other shapes (other edges or faces) the algorithm uses them for creation of common blocks. The information of the possibility for the edges to be split is saved in its PaveBlocks, in the new BOPDS_PaveBlock::myIsSplittable field. It can be retrieved by the BOPDS_PaveBlock::IsSplittable() or BOPDS_PaveBlock::ShrunkData(), but these methods make sense only after filling of the shrunk data for the pave block. BOPTools_AlgoTools::IsMicroEdge() has an additional parameter that defines whether it is necessary to take into account the possibility for the edge to be split or not. By default it is set to TRUE, i.e. by default the edge will be considered as micro even if the shrunk range is computed, but it is too short for the edge to be split. 3. BOPAlgo_PaveFiller::PerformEF To avoid creation of too close intersection vertices the intersection ranges of the edges participating in Edge/Face intersections are reduced taking into account the common ranges computed during Edge/Edge intersections. Thus, the Edge/Face intersection vertex is not created if it gets into a common range of the Edge/Edge intersection between that edge and one of the face's edges. The tolerance value of Edge/Edge intersection vertex is increased to reach the Edge/Face intersection. 4. Unification of the vertices of the section edges considered as micro edges. If by the result of some Face/Face intersection the section edge is considered as micro edge, the vertices of this edge will be united and the edge itself will be removed. 5. Test cases for the issues. 6. Adjusting test cases for issue CR27448.
-
- 29 Mar, 2016 1 commit
-
-
nbv authored
1. New sharing algorithm has been implemented. If intermediate point of some edge is included in the tube with center taken in another edge and radius equaled to maximal vertex-tolerance of both edges then these two edges are considered to be shared. This know-how touches edges only, which have common blocks with interfered faces. If they do not have any common-blocks the algorithm will work as before. 2. Interface of BOPAlgo_PaveFiller::IsExistingPaveBlock(...) method has been changed. Creation of test case for issues #27128 and #27179 Adjusting some test cases according to their new behavior, because they are IMPROVEMENTS really (TODOs have been deleted).
-
- 13 Jan, 2016 1 commit
-
-
msv authored
- Avoid reducing tolerance of the original edges in BOPAlgo_PaveFiller::CorrectToleranceOfSE - If a boundary edge is considered coincident with a section curve then increase its tolerance more carefully, using real distance instead of extended reached tolerance. - New test case bugs/modalg_6/bug27032 - Test cases boolean/gdml_private/E4-F3 have been amended to check area of the result. - Puts TODO in test cases boolean gdml_private ZI5,ZI7,ZJ7.
-
- 23 Dec, 2015 1 commit
-
-
msv authored
0026796: The result of General Fuse operation is self-intersecting shape The fix forces creation of new sub-shapes (vertex, edge) when the tolerance of some sub-shape of an argument is to be increased. This new behavior is turned off by default. It can be turned on using two ways: 1) Setting 'locking' flag of the arguments. 2) Calling the method SetNonDestructive(Standard_True) of the API classes. Various bug fixes in the algorithm: - Compute correct tolerance values for intersections of type Line/Line, Line/Plane, Plane/Plane. - In case of Line/Plane intersection check if line's vertices lie on the plane. - Do not allow decreasing of the tolerance value of the Line/Line intersection vertex. - In IntTools_EdgeEdge, call the method FindParameters with proper 3D tolerance of the curve. - Force making copy of a degenerated edge if its vertex is touched but no 2D intersection with other curves is found. - Remove pave blocks both ends of which became referring to the same vertex after vertices substitution. - Avoid exception in IntTools_Context::IsVertexOnLine if Extrema is not done. - Reduce tolerance of vertex/edge using actual distances to interfered shapes if it was increased due to line/line, line/plane, or plane/plane small intersection angle. - Update tolerance of edges to reach all representations in a common block. - In V-E intersections, check if a vertex hits beyond shrunk range, in such case create V-V interference. - Do not put a section edge to the result if it becomes to be a micro edge after updating its vertex. - Correctly make vertices same-domain during the work of MakeBlocks. - Decrease shrunk range at least on a Precision::Confusion() in addition to vertex tolerance. - Add Confusion to bounding boxes of new shapes in DS - Add tolerance Precision::Confusion() to compare distances of touching cases to fix regressions. TODO marks have been removed from (or modified in) the following test cases (Improvements): boolean bsection M3 N2 R2 boolean gdml_private B6 C2 C6 G7 I6 F6 J1 J4 M7 N1 N8 N9 O3 O4 O6 O8 O9 P1 P2 P5 Q1 Q3 Q5 S9 T2 U4 U5 U9 ZB5 ZB6 ZC1 ZC5 ZD3 ZD6 ZD7 ZH2 ZH5 ZI2 ZI5 ZI7 ZI9 ZJ3 ZJ4 ZJ7 F8 I6 G1 boolean volumemaker A5 A6 B3 B4 B7 B9 D3 D4 D7 F1 boolean bopcut_2d D5 bugs modalg_5 bug25043 bugs modalg_2 bug472_1 bug472_2 bug472_3 Test cases updated because they are still bad but can be accepted as non-regression: boolean volumemaker C4 A3 A7 E6 bugs modalg_1 bug10232 boolean bsection N2 Put new TODO in the scripts: bugs modalg_5 bug25232_9 bugs modalg_6 bug26619 bugs modalg_1 buc60462_2 bugs modalg_4 bug772 For the following tests the result in fix became better, so take fix result as the reference: bugs modalg_5 bug24628 bugs modalg_6 bug26954_3 boolean volumemaker A4 B5 B6 C3 C8 D2 D5 F2 bugs modalg_2 bug472_2 bugs modalg_1 buc60776_1 - Add the method SetNonDestructive to API classes of user level
-
- 17 Sep, 2015 1 commit
-
-
isn authored
0026515: Exponential memory usage problems with BOPDS_IndexedMapOfPaveBlock and NCollection_IncAllocator Correcting the usage of NCollection_IncAllocator Conflicts: src/BOPAlgo/BOPAlgo_BOP.cxx src/BOPAlgo/BOPAlgo_Builder.cxx src/BOPAlgo/BOPAlgo_BuilderSolid.cxx src/BOPAlgo/BOPAlgo_Builder_2.cxx src/BOPAlgo/BOPAlgo_MakerVolume.cxx src/BOPAlgo/BOPAlgo_PaveFiller.cdl src/BOPAlgo/BOPAlgo_PaveFiller_1.cxx src/BOPAlgo/BOPAlgo_PaveFiller_10.cxx src/BOPAlgo/BOPAlgo_PaveFiller_3.cxx src/BOPAlgo/BOPAlgo_PaveFiller_4.cxx src/BOPAlgo/BOPAlgo_PaveFiller_5.cxx src/BOPAlgo/BOPAlgo_PaveFiller_6.cxx src/BOPAlgo/BOPAlgo_PaveFiller_7.cxx src/BOPAlgo/BOPAlgo_PaveFiller_8.cxx src/BOPAlgo/BOPAlgo_Section.cxx src/BOPDS/BOPDS_DS.cxx src/BOPDS/BOPDS_Iterator.cxx src/BOPDS/BOPDS_IteratorSI.cxx src/BOPDS/BOPDS_SubIterator.cxx src/BOPTest/BOPTest_BOPCommands.cxx src/BOPTest/BOPTest_PartitionCommands.cxx src/IntTools/IntTools_Context.cxx additional corrections Adaptation of test case bugs fclasses bug7287_1 (limit for detection of memory leak reduced due to leak reduction) Adjusting test-case bugs fclasses bug7287_1
-
- 12 Jul, 2015 2 commits
-
-
abv authored
Code corrected to avoid passing object to function as non-const reference to handle of the base type where it is not necessary.
-
abv authored
Automatic upgrade of OCCT code by command "occt_upgrade . -nocdl": - WOK-generated header files from inc and sources from drv are moved to src - CDL files removed - All packages are converted to nocdlpack
-