Slicer  4.10
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
vtkMRMLViewLogic.h
Go to the documentation of this file.
1 /*==============================================================================
2 
3  Copyright (c) Kapteyn Astronomical Institute
4  University of Groningen, Groningen, Netherlands. All Rights Reserved.
5 
6  See COPYRIGHT.txt
7  or http://www.slicer.org/copyright/copyright.txt for details.
8 
9  Unless required by applicable law or agreed to in writing, software
10  distributed under the License is distributed on an "AS IS" BASIS,
11  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  See the License for the specific language governing permissions and
13  limitations under the License.
14 
15  This file was originally developed by Davide Punzo, Kapteyn Astronomical Institute,
16  and was supported through the European Research Council grant nr. 291531.
17 
18 ==============================================================================*/
19 
20 #ifndef __vtkMRMLViewLogic_h
21 #define __vtkMRMLViewLogic_h
22 
23 // MRMLLogic includes
24 #include "vtkMRMLAbstractLogic.h"
25 
26 // STD includes
27 #include <vector>
28 #include <deque>
29 
30 class vtkMRMLDisplayNode;
33 class vtkMRMLModelNode;
34 class vtkMRMLViewNode;
35 class vtkMRMLCameraNode;
36 class vtkMRMLVolumeNode;
37 
38 class vtkAlgorithmOutput;
39 class vtkCollection;
40 class vtkImageBlend;
41 class vtkTransform;
42 class vtkImageData;
43 class vtkImageReslice;
44 class vtkTransform;
45 
46 struct SliceLayerInfo;
47 struct BlendPipeline;
48 
55 class VTK_MRML_LOGIC_EXPORT vtkMRMLViewLogic : public vtkMRMLAbstractLogic
56 {
57 public:
59  static vtkMRMLViewLogic *New();
61  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
62 
64  vtkSetStringMacro(Name);
65  vtkGetStringMacro(Name);
66 
68  vtkGetObjectMacro (ViewNode, vtkMRMLViewNode);
69  void SetViewNode (vtkMRMLViewNode* newViewNode);
70 
72  vtkGetObjectMacro (CameraNode, vtkMRMLCameraNode);
73  void SetCameraNode (vtkMRMLCameraNode* newCameraNode);
74 
78  void StartCameraNodeInteraction(unsigned int parameters);
79 
81  void EndCameraNodeInteraction();
82 
86  void StartViewNodeInteraction(unsigned int parameters);
87 
89  void EndViewNodeInteraction();
90 
92  void UpdateCameraNode();
93 
95  void UpdateViewNode();
96 
99  static vtkMRMLViewNode* GetViewNode(vtkMRMLScene* scene,
100  const char* layoutName);
101 
104  static vtkMRMLCameraNode* GetCameraNode(vtkMRMLScene* scene,
105  const char* layoutName);
106 
107 protected:
109  virtual ~vtkMRMLViewLogic();
110 
111  virtual void SetMRMLSceneInternal(vtkMRMLScene* newScene) VTK_OVERRIDE;
112 
113  virtual void OnMRMLSceneNodeAdded(vtkMRMLNode* node) VTK_OVERRIDE;
114  virtual void OnMRMLSceneNodeRemoved(vtkMRMLNode* node) VTK_OVERRIDE;
115  virtual void UpdateFromMRMLScene() VTK_OVERRIDE;
116 
117  void UpdateMRMLNodes();
118 
119  char* Name;
120  vtkMRMLViewNode* ViewNode;
121  vtkMRMLCameraNode* CameraNode;
122 
123 private:
125  void operator=(const vtkMRMLViewLogic&);
126 
127 };
128 
129 #endif
Superclass for MRML logic classes.
MRML node to represent a display property of 3D surface model.
MRML node to represent a 3D surface model.
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
MRML node for representing a linear transformation.
A set of MRML Nodes that supports serialization and undo/redo.
Definition: vtkMRMLScene.h:54
virtual void OnMRMLSceneNodeAdded(vtkMRMLNode *)
virtual void OnMRMLSceneNodeRemoved(vtkMRMLNode *)
virtual void SetMRMLSceneInternal(vtkMRMLScene *newScene)
MRML node for representing a volume (image stack).
Slicer logic class for view manipulation.
MRML node to represent a 3D view.
MRML node to represent camera node.
Abstract class that contains graphical display properties for displayable nodes.
virtual void UpdateFromMRMLScene()
Abstract Superclass for all specific types of MRML nodes.
Definition: vtkMRMLNode.h:138
static vtkMRMLAbstractLogic * New()