Medical Imaging Interaction Toolkit  2024.06.00
Medical Imaging Interaction Toolkit
mitkMedSAMTool.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 mitkMedSAMTool_h
14 #define mitkMedSAMTool_h
15 
19 #include <mitkRenderingManager.h>
20 
21 namespace us
22 {
23  class ModuleResource;
24 }
25 
26 namespace mitk
27 {
37  {
38  public:
40  itkFactorylessNewMacro(Self);
41  itkCloneMacro(Self);
42 
43  const char *GetName() const override;
44 
45  void Activated() override;
46  void Deactivated() override;
47  bool HasPicks() const override;
48  void ClearPicks() override;
49  void ConnectActionsAndFunctions() override;
50  std::string GetPointsAsCSVString(const mitk::BaseGeometry *baseGeometry) const override;
51 
56  void OnRenderWindowClicked(StateMachineAction *, InteractionEvent *interactionEvent);
57 
62  void OnDelete(StateMachineAction *, InteractionEvent *);
63 
64  protected:
65  MedSAMTool() = default;
66  ~MedSAMTool() = default;
67 
68  private:
73  void CreateBoundingShapeInteractor(bool rotationEnabled);
74 
79  mitk::Geometry3D::Pointer InitializeWithImageGeometry(const mitk::BaseGeometry *geometry) const;
80  DataNode::Pointer m_BoundingBoxNode;
81  BoundingShapeInteractor::Pointer m_BoundingShapeInteractor;
82  };
83 }
84 #endif
mitk::InteractionEvent
Definition: mitkInteractionEvent.h:26
us
Definition: mitkAbstractFileReader.h:29
itk::SmartPointer< Self >
mitk::SegmentAnythingTool
Segment Anything Model interactive 2D tool class.
Definition: mitkSegmentAnythingTool.h:39
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitk::EventStateMachine
‍**
Definition: mitkEventStateMachine.h:111
mitk::MedSAMTool
Medical Segment Anything Model interactive 2D tool class.
Definition: mitkMedSAMTool.h:36
mitk::BaseGeometry
BaseGeometry Describes the geometry of a data object.
Definition: mitkBaseGeometry.h:94
MITKSEGMENTATION_EXPORT
#define MITKSEGMENTATION_EXPORT
Definition: MitkSegmentationExports.h:15
mitk::StateMachineAction
Represents an action, that is executed after a certain event (in statemachine-mechanism) TODO: implem...
Definition: mitkStateMachineAction.h:30
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
MitkSegmentationExports.h
mitkRenderingManager.h
mitkBoundingShapeInteractor.h
mitkSegmentAnythingTool.h