iMSTK
Interactive Medical Simulation Toolkit
imstkVertexPicker.h
1 /*
2 ** This file is part of the Interactive Medical Simulation Toolkit (iMSTK)
3 ** iMSTK is distributed under the Apache License, Version 2.0.
4 ** See accompanying NOTICE for details.
5 */
6 
7 #pragma once
8 
9 #include "imstkPickingAlgorithm.h"
10 
11 namespace imstk
12 {
13 class ImplicitGeometry;
14 
22 {
23 public:
24  VertexPicker();
25  ~VertexPicker() override = default;
26 
27  void requestUpdate() override;
28 
29  void setPickingGeometry(std::shared_ptr<ImplicitGeometry> pickGeometry) { m_pickGeometry = pickGeometry; }
30  std::shared_ptr<ImplicitGeometry> getPickGeometry() const { return m_pickGeometry; }
31 
32 protected:
33  std::shared_ptr<ImplicitGeometry> m_pickGeometry = nullptr;
34 };
35 } // namespace imstk
Abstract functor for picking/selecting of geometry. Differs from collision in that the picking criter...
Picks vertices of geomToPick via those that that are intersecting pickingGeom.
void requestUpdate() override
Users can implement this for the logic to be run.
Compound Geometry.