View Issue Details

IDProjectCategoryView StatusLast Update
0028527Open CASCADEOCCT:Visualizationpublic2018-10-08 18:11
Reporterkgv Assigned Toabv 
PrioritynormalSeveritymajor 
Status closedResolutionfixed 
Product Version7.1.0 
Target Version7.2.0Fixed in Version7.2.0 
Summary0028527: Visualization, AIS_InteractiveContext - custom selection presentation is never removed from View
DescriptionSelectMgr_SelectableObject stores two custom presentations mySelectionPrs and myHilightPrs, which are used by advanced presentable objects like MeshVS_Mesh.

SelectMgr_SelectableObject::ClearSelected() clears the *content* of mySelectionPrs presentation (e.g. graphic groups) but does NOT actually remove presentation from View - and there are no other place for doing this, thus this presentation is never destroyed even after removal of Interactive Object itself, causing memory leak and other issues.

Another potential issue is that SelectMgr_SelectableObject::ClearSelected() is called by AIS_InteractiveContext::Erase()/Remove() by checking flag SelectMgr_SelectableObject::IsAutoHilight() - which still might lead to memory leaks if presentation uses mySelectionPrs (for any auxiliary reasons) regardless of IsAutoHilight() flag.
Steps To Reproduce
pload MODELING XDE VISUALIZATION
box b -100 0 0 10 20 30
vclear
vinit View1
meshfromstl m [locate_data_file OMF6391_box.stl]
vfit
vsetdispmode m 2
vselmode m 8 1
vselect 0 0 409 409 0 409
vclear

vdisplay b
vfit

Result: Fit All take into account bounding box of removed presentation
TagsNo tags attached.
Test case numberNot required

Relationships

related to 0030218 closedapn Open CASCADE Visualization - custom selection presentation is not updated within SelectMgr_SelectableObject::UpdateTransformation() 

Activities

git

2017-08-17 11:43

administrator   ~0069507

Branch CR28527 has been created by kgv.

SHA-1: 89958cc91df80bb0477cd997755acb7eafac7840


Detailed log of new commits:

Author: kgv
Date: Thu Aug 17 11:43:08 2017 +0300

    0028527: Visualization, AIS_InteractiveContext - custom selection presentation is never removed from View

kgv

2017-08-17 14:45

developer   ~0069524

Please take the patch.

http://jenkins-test-10.nnov.opencascade.com/view/CR28527-master-KGV

bugmaster

2017-08-17 15:19

administrator   ~0069530

Combination -
OCCT branch : CR28527 : SHA-1: 89958cc91df80bb0477cd997755acb7eafac7840
Products branch : master
was compiled on Linux, MacOS and Windows platforms and tested on optimize mode.

Number of compiler warnings:

OCCT :
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS : 0 (0 on master)

Products :
Linux: 5 (5 on master)
Windows: 0 (0 on master)
MacOS : 0 (0 on master)

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:

Windows:
OCCT
Total CPU difference: 17330.010689098726 / 17295.75286949859 [+0.20%]
Producst
Total CPU difference: 7688.758886599963 / 7720.302288799964 [-0.41%]

Linux:
OCCT
Total CPU difference: 19451.89000000023 / 19456.560000000376 [-0.02%]
Products
Total CPU difference: 7703.40000000009 / 7725.120000000072 [-0.28%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention

git

2017-08-18 17:00

administrator   ~0069622

Branch CR28527 has been deleted by kgv.

SHA-1: 89958cc91df80bb0477cd997755acb7eafac7840

Related Changesets

occt: master 905b0e31

2017-08-17 08:43:08

abv


Committer: abv Details Diff
0028527: Visualization, AIS_InteractiveContext - custom selection presentation is never removed from View Affected Issues
0028527
mod - src/AIS/AIS_InteractiveContext.cxx Diff File
mod - src/SelectMgr/SelectMgr_SelectableObject.cxx Diff File
mod - src/SelectMgr/SelectMgr_SelectableObject.hxx Diff File

Issue History

Date Modified Username Field Change
2017-03-08 17:11 kgv New Issue
2017-03-08 17:11 kgv Assigned To => kgv
2017-03-08 17:11 kgv Severity minor => major
2017-03-08 17:16 kgv Description Updated
2017-08-17 11:43 git Note Added: 0069507
2017-08-17 14:45 kgv Note Added: 0069524
2017-08-17 14:45 kgv Assigned To kgv => bugmaster
2017-08-17 14:45 kgv Status new => resolved
2017-08-17 14:45 kgv Status resolved => reviewed
2017-08-17 15:19 bugmaster Note Added: 0069530
2017-08-17 15:19 bugmaster Status reviewed => tested
2017-08-18 12:53 abv Changeset attached => occt master 905b0e31
2017-08-18 12:53 abv Assigned To bugmaster => abv
2017-08-18 12:53 abv Status tested => verified
2017-08-18 12:53 abv Resolution open => fixed
2017-08-18 13:09 bugmaster Test case number => Not required
2017-08-18 17:00 git Note Added: 0069622
2017-09-29 16:17 aiv Fixed in Version => 7.2.0
2017-09-29 16:29 aiv Status verified => closed
2018-10-08 18:11 kgv Relationship added related to 0030218