MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0032450Open CASCADE[OCCT] OCCT:Modeling Algorithmspublic2021-06-16 19:032021-09-11 14:06
Reporterasuraven 
Assigned Tobugmaster 
PrioritynormalSeverityminor 
StatusverifiedResolutionfixed 
PlatformOSOS Version
Product Version 
Target Version[OCCT] 7.6.0*Fixed in Version 
Summary0032450: Modeling Algorithms - change BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface interfaces to adaptors
DescriptionIt is more correct to use adaptors instead of geometry in BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface classes’ interfaces. It should be borne in mind that the adaptors classes aren’t thread safe.
A patch file with implementation of this task (without thread safety) from CR29059-6 branch is attached.
Steps To Reproducenot exist
TagsNo tags attached.
Test case numberNot required
Attached Filespatch file icon 0029059_6-It-is-necessary-to-have-a-unique-way-of-chec.patch (70,299 bytes) 2021-06-16 19:03

- Relationships
related to 0029059verifiedbugmaster Modeling Algorithms - It is necessary to have a unique way of checking of the validity of the edge and its 2D curves 
related to 0032449closedbugmaster Modeling Algorithms - make curves adaptors classes thread safe 
related to 0032485verifiedbugmaster Modeling Algorithms - Add Clone() function for adapters 

-  Notes
(0102852)
git (administrator)
2021-07-28 17:31

Branch CR32450 has been created by asuraven.

SHA-1: 546dcf2f43b12c9d5ba6d043b5e9582cd68d480b


Detailed log of new commits:

Author: asuraven
Date: Tue Jul 13 17:17:51 2021 +0300

    0032450: Modeling Algorithms - change BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface interfaces to adapters
(0102863)
asuraven (developer)
2021-07-28 20:34

(0102875)
asuraven (developer)
2021-07-29 19:06

(0102898)
git (administrator)
2021-07-30 17:21

Branch CR32450_1 has been created by asuraven.

SHA-1: ef0409d05da7b89bcf0d834a7ad078d5ced342c4


Detailed log of new commits:

Author: asuraven
Date: Tue Jul 13 17:17:51 2021 +0300

    0032450: Modeling Algorithms - change BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface interfaces to adapters
(0102901)
asuraven (developer)
2021-07-30 18:15

Michael, please make a preliminary review of the code in the CR32450_1 branch. There are no test results in the branch because the server is currently off
(0102940)
msv (developer)
2021-08-02 20:58

src/GeomLib/GeomLib_CheckCurveOnSurface.hxx
class GeomAdaptor_Curve;
class Adaptor2d_Curve2d;
class Geom_Surface;
class Geom2d_Curve;

These definitions are not used and can be omitted.

  //! and 2d curve <thePCurve>

thePCurve -> theCurveOnSurface

typedef NCollection_Shared<NCollection_Array1<Handle(Adaptor3d_Curve)> > HArray1OfHCurve;


Move this definition out of global scope, inside the class or in the cpp file.

src/GeomLib/GeomLib_CheckCurveOnSurface.cxx
-   const Adaptor3d_Curve& myCurve1;
-   const Adaptor3d_Curve& myCurve2;
+   const Handle(Adaptor3d_Curve)& myCurve1;
+   const Handle(Adaptor3d_Curve)& myCurve2;

It is better to leave here adaptors by reference to value.

-  if(((myCurve->FirstParameter() - myFirst) > myTolRange) ||
-     ((myCurve->LastParameter() - myLast) < -myTolRange) ||
-     ((thePCurve->FirstParameter() - myFirst) > myTolRange) ||
-     ((thePCurve->LastParameter() - myLast) < -myTolRange))
-  {
-    myErrorStatus = 2;
-    return;
-  }

Do not throw away these checks, as you need to check the ends of myCurve and theCurveOnSurface.

    if (isMultiThread)

Why not to use OSD_ThreadPool::Launcher in both cases? You create HArray1OfHCurve in any way. It is better to avoid such code duplication.

      const int aNbThreads = isMultiThread ? Min(anIntervals.Size(), aThreadPool->NbDefaultThreadsToLaunch()) 
: 1;

In this place isMultiThread is always true.

      Handle(HArray1OfHCurve) aCurveArray = new HArray1OfHCurve(0, aNbThreads - 1);

The usage of handle here is not justified. Replace with:
      Array1OfHCurve aCurveArray (0, aNbThreads - 1);

And make GeomLib_CheckCurveOnSurface_Local accepting arrays by reference instead of handles.

src/BRepLib/BRepLib_CheckCurveOnSurface.hxx
  Standard_EXPORT void Perform(const Standard_Boolean isMultiThread = Standard_True);

Change default value to false.

src/BRepLib/BRepLib_CheckCurveOnSurface.cxx
#include <GeomAdaptor_Surface.hxx>

Useless include.

Please add info about changed API in upgrade guide.
(0102941)
msv (developer)
2021-08-02 20:58

(0103243)
git (administrator)
2021-08-16 18:17

Branch CR32450_2 has been created by asuraven.

SHA-1: 9cd2cd687a50d54c212dc4524a5491fb98abed26


Detailed log of new commits:

Author: asuraven
Date: Tue Jul 13 17:17:51 2021 +0300

    0032450: Modeling Algorithms - change BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface interfaces to adapters
(0103248)
asuraven (developer)
2021-08-17 11:31

(0103250)
git (administrator)
2021-08-17 11:47

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: 836179704443501e6533ef8c453638e6170cd763
(0103255)
git (administrator)
2021-08-17 12:56

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: 004a33ee2c49ad858a4b77a36e3092b655d8598d
(0103257)
git (administrator)
2021-08-17 13:19

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: 2631f178e50a1ebeb00e9441e89ab8e2babc1994
(0103260)
git (administrator)
2021-08-17 14:03

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: a3a07bdd52f75021badb6db0eebc9816f2c1e5b6
(0103261)
git (administrator)
2021-08-17 15:07

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: cceb303aa6981944d2117d91bff127c562fca54d
(0103265)
asuraven (developer)
2021-08-17 17:34

(0103530)
git (administrator)
2021-08-30 12:23

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: d0aadfaee4d58fea8da7e060a89e531579e16534
(0103596)
asuraven (developer)
2021-08-31 19:34

remarks fixed in branch CR32450_2
(0103598)
kgv (developer)
2021-08-31 19:47

+Now the classes accept adaptors instead objects as incoming paramrters.
...
+The folowing functions in *GeomLib_CheckCurveOnSurface* have been modified:

paramrters->parameters
folowing->following
incoming->input

It would be helpful configuring a spellchecker within your text editor.
(0103617)
asuraven (developer)
2021-09-01 12:38

tests results:
http://jenkins-test-occt.nnov.opencascade.com/view/CR32450_2-master-ASURAVEN/view/COMPARE/ [^]
(0103621)
msv (developer)
2021-09-01 13:09

Please make a note in upgrade guide that the parameter isMultiThread changed its default value from true to false.

src/GeomLib/GeomLib_CheckCurveOnSurface.hxx
  //! and 2d curve <thePCurve>

Correct the comment: thePCurve -> theCurveOnSurface

src/GeomLib/GeomLib_CheckCurveOnSurface.cxx
      const Handle(Adaptor3d_Curve)& anAdaptorCurve = theCurveOnSurface;
      aCurveOnSurfaceArray.SetValue(anI, aNbThreads > 1 ? theCurveOnSurface->ShallowCopy() : anAdaptorCurve);


It is no need to introduce the new variable anAdaptorCurve.
(0103623)
git (administrator)
2021-09-01 13:48

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: 1dc1eef23f7e76fa4e1b16f161c9cf7a350ca8ae
(0103627)
asuraven (developer)
2021-09-01 13:52

fixed
(0103629)
msv (developer)
2021-09-01 14:30

For integration:
occt - CR32450_2
products - none
(0103665)
smoskvin (administrator)
2021-09-02 11:55

The problems of compilation on Linux platform that block testing CR0-WEEK-35

Rebase branch to CR0-WEEK-35 and check compilation

http://jenkins-test-08.nnov.opencascade.com/view/CR0-WEEK-35/view/OCCT%20compile/job/CR0-WEEK-35-OCCT-Debian80-64-opt-compile/3/parsed_console/ [^]
(0103677)
git (administrator)
2021-09-02 14:34

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: cfaf08f983443bd91e9b906e2e9daf8a002687fe
(0103866)
git (administrator)
2021-09-06 15:00

Branch CR32450_2 has been updated forcibly by asuraven.

SHA-1: 6342b1c888b29df22bd2109f5986b859032f0789
(0103885)
asuraven (developer)
2021-09-07 12:47

Linux compilation problem fixed
(0103919)
git (administrator)
2021-09-08 12:39

Branch CR32450_2 has been updated forcibly by msv.

SHA-1: 1a59c817447bffcd2571c62d842108cfa9f9c429
(0103920)
msv (developer)
2021-09-08 12:40

For integration:
occt - CR32450_2
products - none
(0104002)
smoskvin (administrator)
2021-09-11 13:23

Combination -
OCCT branch : IR-2021-09-10
master SHA - 9ae883970dd77a39d856b49e6883ed5d0e60d20f
49e51745631c52b6c452c65adae4d6dfa21a1b1e
Products branch : IR-2021-09-10 SHA - 2d2bc879e2da9d770a1938ab3410f5885c8555e7
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 17358.54000000042 / 17496.500000000422 [-0.79%]
Products
Total CPU difference: 11397.800000000112 / 11567.680000000111 [-1.47%]
Windows-64-VC14:
OCCT
Total CPU difference: 19328.109375 / 19307.609375 [+0.11%]
Products
Total CPU difference: 12733.328125 / 12920.953125 [-1.45%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0104040)
git (administrator)
2021-09-11 14:06

Branch CR32450 has been deleted by mnt.

SHA-1: 546dcf2f43b12c9d5ba6d043b5e9582cd68d480b
(0104041)
git (administrator)
2021-09-11 14:06

Branch CR32450_1 has been deleted by mnt.

SHA-1: ef0409d05da7b89bcf0d834a7ad078d5ced342c4
(0104042)
git (administrator)
2021-09-11 14:06

Branch CR32450_2 has been deleted by mnt.

SHA-1: 1a59c817447bffcd2571c62d842108cfa9f9c429

- Related Changesets
occt: master 9ae88397
Timestamp: 2021-07-13 14:17:51
Author: asuraven
Committer: bugmaster
Details ] Diff ]
0032450: Modeling Algorithms - change BRepLib_CheckCurveOnSurface & GeomLib_CheckCurveOnSurface interfaces to adapters
mod - dox/upgrade/upgrade.md Diff ] File ]
mod - src/BRepLib/BRepLib_CheckCurveOnSurface.cxx Diff ] File ]
mod - src/BRepLib/BRepLib_CheckCurveOnSurface.hxx Diff ] File ]
mod - src/BRepTools/BRepTools.cxx Diff ] File ]
mod - src/GeomLib/GeomLib_CheckCurveOnSurface.cxx Diff ] File ]
mod - src/GeomLib/GeomLib_CheckCurveOnSurface.hxx Diff ] File ]
mod - src/IntTools/IntTools_Tools.cxx Diff ] File ]

- Issue History
Date Modified Username Field Change
2021-06-16 19:03 asuraven New Issue
2021-06-16 19:03 asuraven Assigned To => msv
2021-06-16 19:03 asuraven File Added: 0029059_6-It-is-necessary-to-have-a-unique-way-of-chec.patch
2021-06-16 19:04 asuraven Relationship added related to 0029059
2021-06-16 19:04 asuraven Relationship added related to 0032449
2021-06-16 19:29 msv Description Updated View Revisions
2021-07-19 12:43 asuraven Relationship added related to 0032485
2021-07-28 11:31 asuraven Assigned To msv => asuraven
2021-07-28 11:31 asuraven Status new => assigned
2021-07-28 17:31 git Note Added: 0102852
2021-07-28 20:34 asuraven Note Added: 0102863
2021-07-29 19:06 asuraven Note Added: 0102875
2021-07-30 17:21 git Note Added: 0102898
2021-07-30 18:15 asuraven Note Added: 0102901
2021-07-30 18:15 asuraven Assigned To asuraven => msv
2021-07-30 18:15 asuraven Status assigned => resolved
2021-07-30 18:15 asuraven Steps to Reproduce Updated View Revisions
2021-08-02 20:58 msv Note Added: 0102940
2021-08-02 20:58 msv Note Added: 0102941
2021-08-02 20:58 msv Assigned To msv => asuraven
2021-08-02 20:58 msv Status resolved => assigned
2021-08-16 18:17 git Note Added: 0103243
2021-08-17 11:31 asuraven Note Added: 0103248
2021-08-17 11:47 git Note Added: 0103250
2021-08-17 12:56 git Note Added: 0103255
2021-08-17 13:19 git Note Added: 0103257
2021-08-17 14:03 git Note Added: 0103260
2021-08-17 15:07 git Note Added: 0103261
2021-08-17 17:34 asuraven Note Added: 0103265
2021-08-30 12:23 git Note Added: 0103530
2021-08-31 19:34 asuraven Note Added: 0103596
2021-08-31 19:34 asuraven Assigned To asuraven => msv
2021-08-31 19:34 asuraven Status assigned => resolved
2021-08-31 19:47 kgv Note Added: 0103598
2021-09-01 12:38 asuraven Note Added: 0103617
2021-09-01 13:09 msv Note Added: 0103621
2021-09-01 13:09 msv Assigned To msv => asuraven
2021-09-01 13:09 msv Status resolved => assigned
2021-09-01 13:48 git Note Added: 0103623
2021-09-01 13:52 asuraven Note Added: 0103627
2021-09-01 13:52 asuraven Assigned To asuraven => msv
2021-09-01 13:52 asuraven Status assigned => resolved
2021-09-01 14:30 msv Note Added: 0103629
2021-09-01 14:30 msv Assigned To msv => bugmaster
2021-09-01 14:30 msv Status resolved => reviewed
2021-09-02 11:55 smoskvin Note Added: 0103665
2021-09-02 11:55 smoskvin Assigned To bugmaster => asuraven
2021-09-02 11:55 smoskvin Status reviewed => assigned
2021-09-02 14:34 git Note Added: 0103677
2021-09-06 15:00 git Note Added: 0103866
2021-09-07 12:47 asuraven Note Added: 0103885
2021-09-07 12:47 asuraven Assigned To asuraven => msv
2021-09-07 12:47 asuraven Status assigned => resolved
2021-09-08 12:39 git Note Added: 0103919
2021-09-08 12:40 msv Note Added: 0103920
2021-09-08 12:40 msv Assigned To msv => bugmaster
2021-09-08 12:40 msv Status resolved => reviewed
2021-09-11 13:23 smoskvin Note Added: 0104002
2021-09-11 13:23 smoskvin Status reviewed => tested
2021-09-11 13:38 smoskvin Test case number => Not required
2021-09-11 13:43 bugmaster Changeset attached => occt master 9ae88397
2021-09-11 13:43 bugmaster Status tested => verified
2021-09-11 13:43 bugmaster Resolution open => fixed
2021-09-11 14:06 git Note Added: 0104040
2021-09-11 14:06 git Note Added: 0104041
2021-09-11 14:06 git Note Added: 0104042


Copyright © 2000 - 2021 MantisBT Team
Powered by Mantis Bugtracker