View Issue Details

IDProjectCategoryView StatusLast Update
0032859CommunityOCCT:Modeling Algorithmspublic2023-03-19 20:16
ReporterManycore Assigned Toifv 
PrioritynormalSeverityminor 
Status closedResolutionfixed 
PlatformWindowsOSVC++ 2015 
Product Version7.7.0 
Target Version7.7.0Fixed in Version7.7.0 
Summary0032859: Modeling Algorithms - BRepLib_FindSurface not return an expect plane
Descriptionthere are two bugs :

> bug1: we expect plane's dx is [1, 0, 0], but return [0, 1, 0], After analyse I find that the return normal is [0, 2.4790833534415498e-33,1], it should be [0, 0, 1]
   we can use newell's method to calc the normal

> bug2: The wire is made by Steps to reproduce the problem, then invoke the BRepLib_FindSurface function, it returns plan1. After serialize and deserialize the wire, the BRepLib_FindSurface function return plane2. plane1 and plane2 are different.
After anylise I find deserialize has changed the first Edge's data, I think deserialize should not change the input data[wire.brep]

> this isuee fix the first bug
 
Steps To Reproduce        gp_Pnt pt0(-500, 25, -6);
    gp_Pnt pt1(-450, -25, -6);
    gp_Pnt pt2(450, -25, -6);
    gp_Pnt pt3(500, 25, -6);
    BRepBuilderAPI_MakeVertex v0(pt0);
    TopoDS_Vertex vertex0 = v0.Vertex();

    BRepBuilderAPI_MakeVertex v1(pt1);
    TopoDS_Vertex vertex1 = v1.Vertex();

    BRepBuilderAPI_MakeVertex v2(pt2);
    TopoDS_Vertex vertex2 = v2.Vertex();

    BRepBuilderAPI_MakeVertex v3(pt3);
    TopoDS_Vertex vertex3 = v3.Vertex();

    BRepBuilderAPI_MakeEdge e0(vertex0, vertex1);
    TopoDS_Edge edge0 = e0.Edge();

    BRepBuilderAPI_MakeEdge e1(vertex1, vertex2);
    TopoDS_Edge edge1 = e1.Edge();

    BRepBuilderAPI_MakeEdge e2(vertex2, vertex3);
    TopoDS_Edge edge2 = e2.Edge();

    BRepBuilderAPI_MakeEdge e3(vertex3, vertex0);
    TopoDS_Edge edge3 = e3.Edge();

    BRepBuilderAPI_MakeWire w0(edge0, edge1, edge2, edge3);
    TopoDS_Wire wire = w0.Wire();

    BRepLib_FindSurface findPlane(wire);
    Handle(Geom_Surface) plane = findPlane.Surface();
TagsNo tags attached.
Test case numberbugs modalg_8 bug32859

Attached Files

  • wire.brep (818 bytes)
  • calc_wire_plane.png (21,384 bytes)

Activities

Manycore

2022-03-02 05:49

developer  

wire.brep (818 bytes)
calc_wire_plane.png (21,384 bytes)

git

2022-03-02 06:18

administrator   ~0107128

Branch CR32859 has been created by Manycore.

SHA-1: 71711b0649bfb600afd113c8a28c301b18e4a52c


Detailed log of new commits:

Author: gelin
Date: Wed Mar 2 11:17:31 2022 +0800

        0032859: BRepLib_FindSurface not return an excepted plane

msv

2022-03-02 18:05

developer   ~0107141

@Manycore, you everywhere in this bug use the word "excepted" (synonym "excluded"). Did you mean "expected" ("anticipated")?

Manycore

2022-03-03 04:43

developer   ~0107155

@msv , sorry, it is a spelling error. I means "expected"

git

2022-09-08 14:11

administrator   ~0110864

Branch CR32859_1 has been created by ifv.

SHA-1: ef472a3ffb77ec53c13d43d4e384b633d1143f9a


No new revisions were added by this update.

ifv

2022-09-09 09:26

developer   ~0110886

Branch CR32859_1 is ready for review

Test results:
http://jenkins-test-08.nnov.opencascade.com/view/CR32859_1-master-ifv/view/COMPARE/

emv

2022-09-09 13:57

developer   ~0110905

Reviewed. Please integrate CR32859_1 into OCCT.

smoskvin

2022-09-11 13:58

administrator   ~0110932

Combination -
OCCT branch : IR-2022-09-09
master SHA - 526c506cb0a6a5c9c168ab5efd0a4e5211e30bf4
e0ceb716c70188b98130b1550914140d0502a6f9
Products branch : IR-2022-09-09 SHA - changes and them, and you can discard any commits you make in this
574253b6b844635a69038511e6920877f837e298
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: 18959.200000000466 / 18756.090000000648 [+1.08%]
Products
Total CPU difference: 12020.780000000137 / 11992.830000000133 [+0.23%]
Windows-64-VC14:
OCCT
Total CPU difference: 20894.5625 / 20851.65625 [+0.21%]
Products
Total CPU difference: 13470.484375 / 13574.0625 [-0.76%]


Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2022-09-11 14:51

administrator   ~0110939

Branch CR32859 has been deleted by mnt.

SHA-1: 71711b0649bfb600afd113c8a28c301b18e4a52c

git

2022-09-11 14:51

administrator   ~0110940

Branch CR32859_1 has been deleted by mnt.

SHA-1: ef472a3ffb77ec53c13d43d4e384b633d1143f9a

Related Changesets

occt: master 526c506c

2022-09-08 14:08:00

ifv


Committer: smoskvin Details Diff
0032859: Modeling Algorithms - BRepLib_FindSurface not return an expect plane

BRepLib/BRepLib_FindSurface.cxx = removing very small values from coordinate of normal
bug32859 - test case added
Affected Issues
0032859
mod - src/BRepLib/BRepLib_FindSurface.cxx Diff File
add - tests/bugs/modalg_8/bug32859 Diff File

Issue History

Date Modified Username Field Change
2022-03-02 05:49 Manycore New Issue
2022-03-02 05:49 Manycore Assigned To => Manycore
2022-03-02 05:49 Manycore File Added: wire.brep
2022-03-02 05:49 Manycore File Added: calc_wire_plane.png
2022-03-02 05:51 Manycore Description Updated
2022-03-02 06:18 git Note Added: 0107128
2022-03-02 06:20 Manycore Assigned To Manycore => msv
2022-03-02 06:20 Manycore Status new => resolved
2022-03-02 18:05 msv Note Added: 0107141
2022-03-03 04:43 Manycore Note Added: 0107155
2022-03-03 04:43 Manycore Summary BRepLib_FindSurface not return an excepted plane => BRepLib_FindSurface not return an expect plane
2022-03-03 04:43 Manycore Description Updated
2022-03-03 11:49 oan Category OCCT:Mesh => OCCT:Modeling Algorithms
2022-03-03 17:33 msv Assigned To msv => ifv
2022-09-08 12:43 ifv Summary BRepLib_FindSurface not return an expect plane => Modeling Algorithms - BRepLib_FindSurface not return an expect plane
2022-09-08 14:11 git Note Added: 0110864
2022-09-09 09:05 ifv Test case number => bugs modalg_8 bug32859
2022-09-09 09:07 ifv Status resolved => assigned
2022-09-09 09:26 ifv Assigned To ifv => msv
2022-09-09 09:26 ifv Status assigned => resolved
2022-09-09 09:26 ifv Note Added: 0110886
2022-09-09 10:55 msv Assigned To msv => emv
2022-09-09 13:57 emv Assigned To emv => bugmaster
2022-09-09 13:57 emv Status resolved => reviewed
2022-09-09 13:57 emv Note Added: 0110905
2022-09-11 13:58 smoskvin Status reviewed => tested
2022-09-11 13:58 smoskvin Note Added: 0110932
2022-09-11 14:40 smoskvin Changeset attached => occt master 526c506c
2022-09-11 14:40 ifv Assigned To bugmaster => ifv
2022-09-11 14:40 ifv Status tested => verified
2022-09-11 14:40 ifv Resolution open => fixed
2022-09-11 14:51 git Note Added: 0110939
2022-09-11 14:51 git Note Added: 0110940
2023-03-19 20:16 vglukhik Status verified => closed
2023-03-19 20:16 vglukhik Fixed in Version => 7.7.0