| 1607 | } |
| 1608 | |
| 1609 | void vtkParallelCoordinatesRepresentation::UpdateSelectionActors() |
| 1610 | { |
| 1611 | vtkSelection* selection = this->GetAnnotationLink()->GetCurrentSelection(); |
| 1612 | int numNodes = selection->GetNumberOfNodes(); |
| 1613 | |
| 1614 | for (int i = 0; i < numNodes; i++) |
| 1615 | { |
| 1616 | while (i >= (int)this->I->SelectionData.size()) |
| 1617 | { |
| 1618 | // initialize everything for drawing the selection |
| 1619 | vtkSmartPointer<vtkPolyData> polyData = vtkSmartPointer<vtkPolyData>::New(); |
| 1620 | vtkSmartPointer<vtkActor2D> actor = vtkSmartPointer<vtkActor2D>::New(); |
| 1621 | vtkSmartPointer<vtkPolyDataMapper2D> mapper = vtkSmartPointer<vtkPolyDataMapper2D>::New(); |
| 1622 | mapper.TakeReference(this->InitializePlotMapper(polyData, actor)); |
| 1623 | |
| 1624 | this->I->SelectionData.push_back(polyData); |
| 1625 | this->I->SelectionMappers.push_back(mapper); |
| 1626 | this->I->SelectionActors.push_back(actor); |
| 1627 | |
| 1628 | this->AddPropOnNextRender(actor); |
| 1629 | } |
| 1630 | } |
| 1631 | |
| 1632 | for (int i = numNodes; i < (int)this->I->SelectionData.size(); i++) |
| 1633 | { |
| 1634 | this->RemovePropOnNextRender(this->I->SelectionActors[i]); |
| 1635 | this->I->SelectionData.pop_back(); |
| 1636 | this->I->SelectionMappers.pop_back(); |
| 1637 | this->I->SelectionActors.pop_back(); |
| 1638 | } |
| 1639 | |
| 1640 | this->BuildInverseSelection(); |
| 1641 | } |
| 1642 | |
| 1643 | //------------------------------------------------------------------------------ |
| 1644 | int vtkParallelCoordinatesRepresentation::ComputePointPosition(double* p) |
no test coverage detected