Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkVtkGLMapperWrapper.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 MITKVtkGLMapperWrapper_H_HEADER
18 #define MITKVtkGLMapperWrapper_H_HEADER
19 
20 #include "mitkBaseRenderer.h"
21 #include "mitkGLMapper.h"
23 #include "mitkVtkMapper.h"
24 #include <MitkLegacyGLExports.h>
25 #include <vtkSmartPointer.h>
26 
27 class vtkGLMapperProp;
28 
29 namespace mitk
30 {
35  {
36  public:
38 
40 
41  itkCloneMacro(Self)
42 
43 
44  virtual vtkProp *GetVtkProp(mitk::BaseRenderer *renderer) override;
45 
46  virtual void GenerateDataForRenderer(mitk::BaseRenderer *renderer) override;
47 
50  {
51  public:
52  /* constructor */
53  LocalStorage();
54 
55  /* destructor */
56  ~LocalStorage();
57  vtkSmartPointer<vtkGLMapperProp> m_GLMapperProp;
58  };
59 
60  virtual void ApplyColorAndOpacityProperties(mitk::BaseRenderer *renderer, vtkActor *actor) override;
61 
62  void MitkRender(mitk::BaseRenderer *renderer, mitk::VtkPropRenderer::RenderType type) override;
63 
64  virtual void Update(BaseRenderer *renderer) override;
65 
66  virtual void SetDataNode(DataNode *node) override;
67 
68  virtual DataNode *GetDataNode() const override;
69 
72 
73  protected:
75  /* constructor */
77 
78  /* destructor */
79  virtual ~VtkGLMapperWrapper();
80  void Enable2DOpenGL(mitk::BaseRenderer *);
81  void Disable2DOpenGL();
82  };
83 
84 } // namespace mitk
85 
86 #endif /* MITKVtkGLMapperWrapper_H_HEADER_INCLUDED_C1902626 */
Base class for mapper specific rendering ressources.
Definition: mitkMapper.h:200
#define mitkNewMacro1Param(classname, type)
Definition: mitkCommon.h:76
mitk::LocalStorageHandler< LocalStorage > m_LSH
The LocalStorageHandler holds all (three) LocalStorages for the three 2D render windows.
Organizes the rendering process.
static void Update(vtkPolyData *)
Definition: mitkSurface.cpp:35
Internal class holding the mapper, actor, etc. for each of the 3 2D render windows.
DataCollection - Class to facilitate loading/accessing structured data.
Vtk-based 2D mapper for PointSet.
Base class of all Vtk Mappers in order to display primitives by exploiting Vtk functionality.
Definition: mitkVtkMapper.h:53
Base class of all mappers, Vtk as well as OpenGL mappers.
Definition: mitkMapper.h:54
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
vtkSmartPointer< vtkGLMapperProp > m_GLMapperProp
virtual void SetDataNode(DataNode *dataNode) override
The vtkGLMapperProp class is a VtkProp, wrapping a GLMapper.
#define MITKLEGACYGL_EXPORT
Class for nodes of the DataTree.
Definition: mitkDataNode.h:66