We have to clear actors in vtkCellPicker object before InitializePickList.

In the function Pick, the picker object will addItem to increase its reference count.

So we need to do the following tasks for picker object in class destructor function to avoid crash or weird visible bug.

m_ItemPicker->GetActors()->RemoveAllItems();
m_ItemPicker->GetProp3Ds()->RemoveAllItems();
m_ItemPicker->InitializePickList();
m_ItemPicker->RemoveAllObservers();
Categories: VTK

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments

Content Summary
: Input your strings, the tool can get a brief summary of the content for you.

X
0
Would love your thoughts, please comment.x
()
x