Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitknnInteractivePointInteractor.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitknnInteractivePointInteractor_h
14 #define mitknnInteractivePointInteractor_h
15 
17 #include <mitkPoint.h>
18 
19 #include <optional>
20 
21 namespace mitk::nnInteractive
22 {
36  {
37  public:
41 
44  ~PointInteractor() override;
45 
51  bool HasInteractions() const override;
52 
60  std::optional<Point3D> GetLastPoint() const;
61 
70  void RemoveLastInteraction(PromptType promptType) override;
71 
72  private:
73  void OnEnable() override;
74  void OnDisable() override;
75  void OnReset() override;
76 
77  class Impl;
78  std::unique_ptr<Impl> m_Impl;
79  };
80 }
81 
82 #endif
#define MITKPYTHONSEGMENTATION_EXPORT
Base class for all nnInteractive interactors.
nnInteractive interactor for placing individual points.
bool HasInteractions() const override
Checks whether any points have been placed.
~PointInteractor() override
Destructor. Calls OnReset() to clean up data nodes.
std::optional< Point3D > GetLastPoint() const
Returns the most recently placed point for the current prompt type.
void RemoveLastInteraction(PromptType promptType) override
Removes the most recently placed point for the given prompt type.
PointInteractor()
Constructs a PointInteractor with InteractionType::Point.
PromptType
Specifies the types of prompts used in nnInteractive.