------------------------------------------------------------------------------
| 113 | |
| 114 | //------------------------------------------------------------------------------ |
| 115 | vtkIdType vtkInteractorStyleAreaSelectHover::GetIdAtPos(int x, int y) |
| 116 | { |
| 117 | vtkIdType id = -1; |
| 118 | |
| 119 | vtkRenderer* r = this->CurrentRenderer; |
| 120 | if (r == nullptr) |
| 121 | { |
| 122 | return id; |
| 123 | } |
| 124 | |
| 125 | // Use the hardware picker to find a point in world coordinates. |
| 126 | this->Picker->Pick(x, y, 0, r); |
| 127 | double pos[3]; |
| 128 | this->Picker->GetPickPosition(pos); |
| 129 | |
| 130 | if (this->Layout) |
| 131 | { |
| 132 | float posFloat[3]; |
| 133 | for (int i = 0; i < 3; i++) |
| 134 | { |
| 135 | posFloat[i] = pos[i]; |
| 136 | } |
| 137 | id = this->Layout->FindVertex(posFloat); |
| 138 | } |
| 139 | |
| 140 | return id; |
| 141 | } |
| 142 | |
| 143 | //------------------------------------------------------------------------------ |
| 144 | void vtkInteractorStyleAreaSelectHover::GetBoundingAreaForItem(vtkIdType id, float* sinfo) |
no test coverage detected