MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0030270Open CASCADE[OCCT] OCCT:Modeling Algorithmspublic2018-10-19 11:502018-10-28 16:13
Reporterkgv 
Assigned Toapn 
PrioritynormalSeverityfeature 
StatusverifiedResolutionfixed 
PlatformOSOS Version
Product Version 
Target Version[OCCT] 7.4.0*Fixed in Version 
Summary0030270: Modeling Algorithms - BRepBndLib should provide an option for skipping infinite entities
DescriptionCurrently, BRepBndLib for a shape having infinite sub-shapes (usually issues coming from Data Exchange - invalid files, or extra entities not expected to be displayed) returns an infinite Bounding Box.

This has several side effects on consequential usage of this Bounding Box in algorithms:
- Estimating relative Linear Deflection parameter for BRepMesh is not possible.
- Efficient spatial splitting of the model is not possible.

It is proposed adding a new mode to BRepBndLib allowing to skip infinite elements within the shape or reporting them independently as two bounding boxes.
Steps To Reproduce
pload MODELING
restore screw_inf.brep s
bounding s
bounding s -obb

Output:
AABB:
  -1e+100 -1e+100 -1e+100 1e+100 1e+100 1e+100
OBB:
  Oriented bounding box
  Center: 0 0 0
  X-axis: 1 0 0
  Y-axis: 0 1 0
  Z-axis: 0 0 1
  Half X: 1e+100
  Half Y: 1e+100
  Half Z: 1e+100

TagsNo tags attached.
Test case numberbugs modalg_7 bug30270
Attached Files? file icon screw_inf.brep (79,905 bytes) 2018-10-19 11:51
png file icon scew_finite_aabb.png (32,153 bytes) 2018-10-23 20:22

- Relationships

-  Notes
(0080236)
git (administrator)
2018-10-23 17:41

Branch CR30270 has been created by kgv.

SHA-1: e8ffc08c4080dc38ef27c736c3787b4212384053


Detailed log of new commits:

Author: kgv
Date: Tue Oct 23 17:39:36 2018 +0300

    0030270: Modeling Algorithms - BRepBndLib should provide an option for skipping infinite entities
    
    Bnd_Box now keeps calculating of finite part of bounding box after specifying it to be Open in some direction.
    The finite part can be retrieved using new method Bnd_Box::FinitePart().
    
    Prs3d::GetDeflection() now uses Bnd_Box::FinitePart() when applying relative deflection.
    
    Draw Harness command bounding has been extended with option -finite returing a finite part of AABB.
(0080237)
git (administrator)
2018-10-23 17:45

Branch CR30270 has been updated forcibly by kgv.

SHA-1: a6bfdfbfe245679b70598fd85333ad7d5b331930
(0080244)
git (administrator)
2018-10-23 20:21

Branch CR30270 has been updated forcibly by kgv.

SHA-1: 62bf1059d48f8cc8d56ce8669c6646e4f57d89cf
(0080246)
kgv (developer)
2018-10-24 08:39

pload MODELING
restore [locate_data_file bug27448_b1255.brep] s
bounding s -print

Output:
Axes-aligned bounding box
X-range: -1e+100 1e+100
Y-range: -51.436175481590702 -4.8637965353791994
Z-range: -1e+100 1e+100
Finite part
X-range: -545.91626374705004 13.037164480842099
Y-range: -51.436175481590702 -4.8637965353791994
Z-range: -13.037164480842099 411.65056290693906


pload MODELING
restore screw_inf.brep s
bounding s -print

Output:
Axes-aligned bounding box
X-range: -1e+100 1e+100
Y-range: -1e+100 1e+100
Z-range: -1e+100 1e+100
Finite part
X-range: -0.049719769446288579 -0.038880230553711419
Y-range: 0.0044607606027138886 0.011500299495291081
Z-range: 0.020980230553711419 0.028019769446288582
(0080247)
kgv (developer)
2018-10-24 08:40

Patch is ready for review.

http://jenkins-test-12.nnov.opencascade.com:8080/view/CR30270-master-KGV/ [^]
(0080258)
git (administrator)
2018-10-24 11:45

Branch CR30270 has been updated by kgv.

SHA-1: 2d9e8691b16247b688f2b753223b4d61fb96d0ab


Detailed log of new commits:

Author: kgv
Date: Wed Oct 24 11:44:27 2018 +0300

    # remarks

(0080259)
git (administrator)
2018-10-24 11:46

Branch CR30270_1 has been created by kgv.

SHA-1: f617d992ccb69a30e430f5972b61aa876b06fcaa


Detailed log of new commits:

Author: kgv
Date: Tue Oct 23 17:39:36 2018 +0300

    0030270: Modeling Algorithms - BRepBndLib should provide an option for skipping infinite entities
    
    Bnd_Box now keeps calculating of finite part of bounding box after specifying it to be Open in some direction.
    The finite part can be retrieved using new method Bnd_Box::FinitePart().
    
    Prs3d::GetDeflection() now uses Bnd_Box::FinitePart() when applying relative deflection.
    
    Draw Harness command bounding has been extended with option -finite returing a finite part of AABB.
(0080260)
kgv (developer)
2018-10-24 11:46

Patch has been updated following remarks.
(0080261)
msv (developer)
2018-10-24 11:49

src/Bnd/Bnd_Box.cxx
- 81: use the same logic as in other Update method: first check IsVoid().

tests/bugs/modalg_7/bug30270
- 10: use smallview instead of axo to reduce snapshot size.
(0080263)
msv (developer)
2018-10-24 11:52

Reviewed.
(0080265)
apn (administrator)
2018-10-24 12:09

Combination -
OCCT branch : CR30270 SHA - 62bf1059d48f8cc8d56ce8669c6646e4f57d89cf
Products branch : master SHA - 35af85def09c66ceeaf90b4e4fb8b54e68d5e98c
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

Test cases:
bugs modalg_7 bug30270 - OK

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 17580.3099999998 / 17520.90999999988 [+0.34%]
Products
Total CPU difference: 7445.660000000032 / 7462.09000000004 [-0.22%]
Windows-64-VC14:
OCCT
Total CPU difference: 17488.07090229844 / 17666.582846598394 [-1.01%]
Products
Total CPU difference: 8364.243216599998 / 8372.402068899986 [-0.10%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0080284)
git (administrator)
2018-10-24 18:20

Branch CR30270_1 has been updated by kgv.

SHA-1: b3baf815521defe3d1e6e369be38c68a44ba7d46


Detailed log of new commits:

Author: kgv
Date: Wed Oct 24 18:04:06 2018 +0300

    # BndLib::Add() - fixed Bnd_Box misuse

(0080285)
git (administrator)
2018-10-24 18:21

Branch CR30270_2 has been created by kgv.

SHA-1: 938e646bf1f0bbe28d0c0e6ecde19b6f38f1f50c


Detailed log of new commits:

Author: kgv
Date: Tue Oct 23 17:39:36 2018 +0300

    0030270: Modeling Algorithms - BRepBndLib should provide an option for skipping infinite entities
    
    Bnd_Box now keeps calculating of finite part of bounding box after specifying it to be Open in some direction.
    The finite part can be retrieved using new method Bnd_Box::FinitePart().
    
    Prs3d::GetDeflection() now uses Bnd_Box::FinitePart() when applying relative deflection.
    
    Draw Harness command bounding has been extended with option -finite returing a finite part of AABB.
(0080408)
git (administrator)
2018-10-28 16:13

Branch CR30270_2 has been deleted by inv.

SHA-1: 938e646bf1f0bbe28d0c0e6ecde19b6f38f1f50c
(0080409)
git (administrator)
2018-10-28 16:13

Branch CR30270_1 has been deleted by inv.

SHA-1: b3baf815521defe3d1e6e369be38c68a44ba7d46
(0080412)
git (administrator)
2018-10-28 16:13

Branch CR30270 has been deleted by inv.

SHA-1: 2d9e8691b16247b688f2b753223b4d61fb96d0ab

- Related Changesets
occt: master 04f0f1b0
Timestamp: 2018-10-23 14:39:36
Author: kgv
Committer: apn
Details ] Diff ]
0030270: Modeling Algorithms - BRepBndLib should provide an option for skipping infinite entities

Bnd_Box now keeps calculating of finite part of bounding box after specifying it to be Open in some direction.
The finite part can be retrieved using new method Bnd_Box::FinitePart().

Prs3d::GetDeflection() now uses Bnd_Box::FinitePart() when applying relative deflection.

Draw Harness command bounding has been extended with option -finite returing a finite part of AABB.
mod - src/Bnd/Bnd_Box.cxx Diff ] File ]
mod - src/Bnd/Bnd_Box.hxx Diff ] File ]
mod - src/BndLib/BndLib.cxx Diff ] File ]
mod - src/BRepTest/BRepTest_BasicCommands.cxx Diff ] File ]
mod - src/Prs3d/Prs3d.cxx Diff ] File ]
add - tests/bugs/modalg_7/bug30270 Diff ] File ]

- Issue History
Date Modified Username Field Change
2018-10-19 11:50 kgv New Issue
2018-10-19 11:50 kgv Assigned To => msv
2018-10-19 11:50 kgv Relationship added child of 0029726
2018-10-19 11:51 kgv Relationship added related to 0029727
2018-10-19 11:51 kgv File Added: screw_inf.brep
2018-10-19 11:52 kgv Steps to Reproduce Updated View Revisions
2018-10-19 11:52 kgv Steps to Reproduce Updated View Revisions
2018-10-23 17:41 git Note Added: 0080236
2018-10-23 17:45 git Note Added: 0080237
2018-10-23 20:21 git Note Added: 0080244
2018-10-23 20:22 kgv File Added: scew_finite_aabb.png
2018-10-24 08:39 kgv Note Added: 0080246
2018-10-24 08:40 kgv Note Added: 0080247
2018-10-24 08:40 kgv Status new => resolved
2018-10-24 08:40 kgv Severity minor => feature
2018-10-24 08:40 kgv Product Version 7.3.0 =>
2018-10-24 11:45 git Note Added: 0080258
2018-10-24 11:46 git Note Added: 0080259
2018-10-24 11:46 kgv Note Added: 0080260
2018-10-24 11:49 msv Note Added: 0080261
2018-10-24 11:50 msv Assigned To msv => kgv
2018-10-24 11:50 msv Status resolved => assigned
2018-10-24 11:52 msv Assigned To kgv => msv
2018-10-24 11:52 msv Status assigned => resolved
2018-10-24 11:52 msv Note Added: 0080263
2018-10-24 11:52 msv Assigned To msv => bugmaster
2018-10-24 11:52 msv Status resolved => reviewed
2018-10-24 12:09 apn Test case number => bugs modalg_7 bug30270
2018-10-24 12:09 apn Note Added: 0080265
2018-10-24 12:09 apn Status reviewed => tested
2018-10-24 18:20 git Note Added: 0080284
2018-10-24 18:21 git Note Added: 0080285
2018-10-25 17:28 kgv Relationship added related to 0029725
2018-10-25 21:25 kgv Relationship added related to 0030307
2018-10-28 13:20 apn Changeset attached => occt master 04f0f1b0
2018-10-28 13:20 apn Assigned To bugmaster => apn
2018-10-28 13:20 apn Status tested => verified
2018-10-28 13:20 apn Resolution open => fixed
2018-10-28 16:13 git Note Added: 0080408
2018-10-28 16:13 git Note Added: 0080409
2018-10-28 16:13 git Note Added: 0080412


Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker