Computer Assited Medical Intervention Tool Kit  version 5.0
SingleImageComponent.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * $CAMITK_LICENCE_BEGIN$
3  *
4  * CamiTK - Computer Assisted Medical Intervention ToolKit
5  * (c) 2001-2021 Univ. Grenoble Alpes, CNRS, Grenoble INP, TIMC, 38000 Grenoble, France
6  *
7  * Visit http://camitk.imag.fr for more information
8  *
9  * This file is part of CamiTK.
10  *
11  * CamiTK is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * CamiTK is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU Lesser General Public License version 3 for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * version 3 along with CamiTK. If not, see <http://www.gnu.org/licenses/>.
22  *
23  * $CAMITK_LICENCE_END$
24  ****************************************************************************/
25 
26 #ifndef SINGLEIMAGEVOLUMECOMPONENT_H
27 #define SINGLEIMAGEVOLUMECOMPONENT_H
28 
29 
30 // -- Core stuff
31 #include "Component.h"
32 #include "Slice.h"
33 
34 // -- QT stuff classes
35 class QMenu;
36 
37 // -- VTK stuff
38 #include <vtkImageReslice.h>
39 #include <vtkWindowLevelLookupTable.h>
40 
41 // -- VTK stuff classes
42 class vtkImageClip;
43 
44 namespace camitk {
62  Q_OBJECT
63 
65  Q_PROPERTY(bool viewSliceIn3D READ getViewSliceIn3D WRITE setViewSliceIn3D)
66 
67 public:
69  SingleImageComponent(Component* parentComponent, Slice::SliceOrientation, const QString& name, vtkSmartPointer<vtkWindowLevelLookupTable> lut);
70 
72  ~SingleImageComponent() override = default;
73 
75  virtual void pixelPicked(double, double, double) override;
76 
78  virtual void setSelected(const bool, const bool) override;
79 
81  virtual void singleImageSelected(const bool);
82 
84 
91  CAMITK_API_DEPRECATED("Please use getVisibility(\"3D Viewer\") instead") virtual bool getViewSliceIn3D() const;
93 
97  CAMITK_API_DEPRECATED("Please use setVisibility(\"3D Viewer\",bool) instead") virtual void setViewSliceIn3D(bool viewSliceIn3D);
99 
103  virtual void setTransform(vtkSmartPointer<vtkTransform>) override;
104  virtual void resetTransform() override;
105  virtual void translate(double, double, double) override;
106  virtual void rotate(double, double, double) override;
107  virtual void rotateVTK(double, double, double) override;
108  virtual void setTransformTranslation(double, double, double) override;
109  virtual void setTransformTranslationVTK(double, double, double) override;
110  virtual void setTransformRotation(double, double, double) override;
111  virtual void setTransformRotationVTK(double, double, double) override;
113 
115  Slice::SliceOrientation getSliceOrientation();
116 
117 protected:
119  virtual void initRepresentation() override final;
120 
122  Slice::SliceOrientation sliceOrientation;
123 
125  vtkSmartPointer<vtkWindowLevelLookupTable> lut;
126 };
127 
128 }
129 
130 #endif
CAMITK_WARNING
#define CAMITK_WARNING(MSG)
Log for warning verbosity (the most common one) Will appear by default.
Definition: Log.h:266
camitk::Slice
Display a slice (i.e. an image or BitMap) of an ImageComponent. Helper class.
Definition: Slice.h:149
SingleImageComponent.h
camitk::ImageComponent
The manager of the Image Volume data. An image volume data has no concrete 3D representation,...
Definition: ImageComponent.h:77
Log.h
camitk::SingleImageComponent
This Component manages sub-component of the image component seen as a single orientation only (axial ...
Definition: SingleImageComponent.h:61
Frame.h
camitk::transform
vtkSmartPointer< vtkTransform > transform
Definition: RendererWidget.cpp:372
Component
A component is something that composed something and could also be a part of something.
Definition: modeling/libraries/pml/Component.h:48
camitk::Viewer
Viewer is an abstract class that is the base class for all viewers.
Definition: Viewer.h:180
camitk::SingleImageComponent::SingleImageComponent
SingleImageComponent(Component *parentComponent, Slice::SliceOrientation, const QString &name, vtkSmartPointer< vtkWindowLevelLookupTable > lut)
Constructor.
Definition: SingleImageComponent.cpp:72
camitk::Slice::SliceOrientation
SliceOrientation
Common slices orientation: axial, sagittal, coronal axial_neuro.
Definition: Slice.h:197
Slice.h
ImageComponent.h
CAMITK_API_DEPRECATED
#define CAMITK_API_DEPRECATED(X)
Definition: CamiTKAPI.h:94
camitk::Component
A Component represents something that could be included in the explorer view, the interactive 3D view...
Definition: sdk/libraries/core/component/Component.h:302
CAMITK_API
#define CAMITK_API
Definition: CamiTKAPI.h:49
camitk
Definition: Action.cpp:35