Medical Imaging Interaction Toolkit  2024.06.99-60d9b802
Medical Imaging Interaction Toolkit
mitkPlanarArrow.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 mitkPlanarArrow_h
14 #define mitkPlanarArrow_h
15 
16 #include "mitkPlanarFigure.h"
18 
19 namespace mitk
20 {
21  class PlaneGeometry;
22 
28  {
29  public:
31 
32  itkFactorylessNewMacro(Self);
33 
34  itkCloneMacro(Self);
35 
41  // virtual void Initialize();
42 
44  unsigned int GetMinimumNumberOfControlPoints() const override
45  {
46  return 2;
47  }
48 
50  unsigned int GetMaximumNumberOfControlPoints() const override { return 2; }
51  void SetArrowTipScaleFactor(float scale);
52 
53  bool Equals(const mitk::PlanarFigure &other) const override;
54 
55  protected:
56  PlanarArrow();
57 
58  mitkCloneMacro(Self);
59 
61  void GeneratePolyLine() override;
62 
64  void GenerateHelperPolyLine(double mmPerDisplayUnit, unsigned int displayHeight) override;
65 
67  void EvaluateFeaturesInternal() override;
68 
69  void PrintSelf(std::ostream &os, itk::Indent indent) const override;
70 
71  // Feature identifiers
72  const unsigned int FEATURE_ID_LENGTH;
73 
74  // ScaleFactor defining size of helper-lines in relation to display size
76 
77  private:
78  };
79 
80 } // namespace mitk
81 
82 #endif
mitk::PlanarArrow::GetMinimumNumberOfControlPoints
unsigned int GetMinimumNumberOfControlPoints() const override
Place figure in its minimal configuration (a point at least) onto the given 2D geometry.
Definition: mitkPlanarArrow.h:44
MitkPlanarFigureExports.h
mitk::PlanarFigure
Base-class for geometric planar (2D) figures, such as lines, circles, rectangles, polygons,...
Definition: mitkPlanarFigure.h:50
MITKPLANARFIGURE_EXPORT
#define MITKPLANARFIGURE_EXPORT
Definition: MitkPlanarFigureExports.h:15
mitkPlanarFigure.h
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitk::PlanarArrow::GetMaximumNumberOfControlPoints
unsigned int GetMaximumNumberOfControlPoints() const override
Line has 2 control points per definition.
Definition: mitkPlanarArrow.h:50
mitk::PlanarArrow::FEATURE_ID_LENGTH
const unsigned int FEATURE_ID_LENGTH
Definition: mitkPlanarArrow.h:72
mitk::PlanarArrow::m_ArrowTipScaleFactor
float m_ArrowTipScaleFactor
Definition: mitkPlanarArrow.h:75
mitk::BaseData
Base of all data objects.
Definition: mitkBaseData.h:42
mitk::PlanarArrow
Implementation of PlanarFigure representing an arrow through two control points.
Definition: mitkPlanarArrow.h:27
mitkCloneMacro
#define mitkCloneMacro(classname)
Definition: mitkCommon.h:154
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36