Medical Imaging Interaction Toolkit  2024.06.99-31d3c0df
Medical Imaging Interaction Toolkit
vtkMitkRectangleProp.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 vtkMitkRectangleProp_h
14 #define vtkMitkRectangleProp_h
15 
16 #include <MitkCoreExports.h>
17 
18 #include <vtkActor2D.h>
19 #include <vtkSmartPointer.h>
20 
21 class vtkPolyData;
22 class vtkViewport;
23 
27 class MITKCORE_EXPORT vtkMitkRectangleProp : public vtkActor2D
28 {
29 public:
30  static vtkMitkRectangleProp *New();
31  vtkTypeMacro(vtkMitkRectangleProp, vtkProp);
32 
33  void SetColor(float red, float green, float blue);
34  void SetLineWidth(unsigned int lineWidth);
35  int RenderOverlay(vtkViewport *viewport) override;
36 
37 protected:
39  ~vtkMitkRectangleProp() override;
40 
41 private:
45  void CreateRectangle();
46  void UpdateRectangle();
47 
48  int m_Height;
49  int m_Width;
50  int m_OriginX;
51  int m_OriginY;
52 
53  vtkIdType m_BottomLeft;
54  vtkIdType m_BottomRight;
55  vtkIdType m_TopRight;
56  vtkIdType m_TopLeft;
57 
62 };
63 
64 #endif
vtkMitkRectangleProp
The vtkMitkRectangleProp class renders a rectangle into a renderwindow as a frame.
Definition: vtkMitkRectangleProp.h:27
vtkSmartPointer< vtkPolyData >
MitkCoreExports.h
MITKCORE_EXPORT
#define MITKCORE_EXPORT
Definition: MitkCoreExports.h:15