Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkColorBarOverlay.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,
6  Division of Medical and Biological Informatics.
7  All rights reserved.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without
10  even the implied warranty of MERCHANTABILITY or FITNESS FOR
11  A PARTICULAR PURPOSE.
12 
13  See LICENSE.txt or http://www.mitk.org for details.
14 
15  ===================================================================*/
16 
17 #ifndef COLORBAROVERLAY_H
18 #define COLORBAROVERLAY_H
19 
20 #include "MitkOverlaysExports.h"
22 #include <mitkVtkOverlay.h>
23 #include <vtkLookupTable.h>
24 #include <vtkSmartPointer.h>
25 
26 class vtkScalarBarActor;
27 
28 namespace mitk
29 {
32  {
33  public:
35  {
36  public:
38  vtkSmartPointer<vtkScalarBarActor> m_ScalarBarActor;
39 
41  itk::TimeStamp m_LastUpdateTime;
42 
44  LocalStorage();
46  ~LocalStorage();
47  };
48 
50  itkFactorylessNewMacro(Self) itkCloneMacro(Self)
51 
52  void SetDrawAnnotations(bool annotations);
53  bool GetDrawAnnotations() const;
54 
55  void SetOrientationToHorizontal();
56  void SetOrientationToVertical();
57  void SetOrientation(int orientation);
58  int GetOrientation() const;
59 
60  void SetMaxNumberOfColors(int numberOfColors);
61  int GetMaxNumberOfColors() const;
62 
63  void SetNumberOfLabels(int numberOfLabels);
64  int GetNumberOfLabels() const;
65 
66  void SetLookupTable(vtkSmartPointer<vtkLookupTable> table);
67  vtkSmartPointer<vtkLookupTable> GetLookupTable() const;
68 
69  void SetDrawTickLabels(bool ticks);
70  bool GetDrawTickLabels() const;
71 
72  void SetAnnotationTextScaling(bool scale);
73  bool GetAnnotationTextScaling() const;
74 
75  protected:
78 
79  virtual vtkProp *GetVtkProp(BaseRenderer *renderer) const override;
80  virtual void UpdateVtkOverlay(BaseRenderer *renderer) override;
81 
83  explicit ColorBarOverlay();
84 
86  virtual ~ColorBarOverlay();
87 
88  private:
90  ColorBarOverlay(const ColorBarOverlay &);
91 
93  ColorBarOverlay &operator=(const ColorBarOverlay &);
94  };
95 
96 } // namespace mitk
97 #endif // COLORBAROVERLAY_H
The VtkOverlay class is the base for all Overlays which are using the VTK framework to render the ele...
Templated class for management of LocalStorage implementations in Mappers.
Organizes the rendering process.
DataCollection - Class to facilitate loading/accessing structured data.
itk::TimeStamp m_LastUpdateTime
Timestamp of last update of stored data.
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
Base class for mapper specific rendering ressources.
Definition: mitkOverlay.h:50
vtkSmartPointer< vtkScalarBarActor > m_ScalarBarActor
Actor of a 2D render window.
#define MITKOVERLAYS_EXPORT
Displays configurable scales on the renderwindow. The scale is determined by the image spacing...
Base class for all overlays.
Definition: mitkOverlay.h:34