The interface vtkAbstractPicker::AddPickList is used to add an object to the bottom of the list. But it will not check adding the same object to the list. So the number of items in the pick list will increase if we add the item multiple times.

Source code for the interface:

// Add an actor to the pick list.
void vtkAbstractPicker::AddPickList(vtkProp* a)
{
  this->Modified();
  this->PickList->AddItem(a);
}


// Add an object to the bottom of the list. Does not prevent duplicate entries.
void vtkCollection::AddItem(vtkObject* a)
{
  vtkCollectionElement* elem;

  elem = new vtkCollectionElement;

  if (!this->Top)
  {
    this->Top = elem;
  }
  else
  {
    this->Bottom->Next = elem;
  }
  this->Bottom = elem;

  a->Register(this);
  elem->Item = a;
  elem->Next = nullptr;

  this->NumberOfItems++;

  this->Modified();
}


int GetNumberOfItems() { return this->NumberOfItems; }
Categories: VTK

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments

XOR Strings
: Input your strings, the tool can encrypt and decrypt them.

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