NorMIT-nav  2023.01.05-dev+develop.0da12
An IGT application
cxSlicerRepSW.h
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 
12 
13 #ifndef CXSLICERREPSW_H_
14 #define CXSLICERREPSW_H_
15 
16 #include "cxResourceVisualizationExport.h"
17 
18 #include "cxRepImpl.h"
19 
20 #include "cxForwardDeclarations.h"
21 #include "vtkForwardDeclarations.h"
22 
23 namespace cx
24 {
25 typedef boost::shared_ptr<class SliceProxyInterface> SliceProxyInterfacePtr;
26 
27 
40 class cxResourceVisualization_EXPORT SliceRepSW : public RepImpl
41 {
42  Q_OBJECT
43 public:
44  static SliceRepSWPtr New(const QString& uid="");
45  virtual ~SliceRepSW();
46  virtual QString getType() const { return "SliceRepSW"; };
47  bool hasImage(ImagePtr image) const;
48  void setImage(ImagePtr image);
49  ImagePtr getImage();
50  vtkImageActorPtr getActor();
51  void setSliceProxy(SliceProxyInterfacePtr slicer);
52  QString getImageUid()const;
53  void update();
54  virtual void printSelf(std::ostream & os, Indent indent);
55 
56 protected:
57  SliceRepSW();
58  virtual void addRepActorsToViewRenderer(ViewPtr view) ;
59  virtual void removeRepActorsFromViewRenderer(ViewPtr view) ;
60 
61 private:
62  SlicedImageProxyPtr mImageSlicer;
63  vtkImageActorPtr mImageActor;
64 };
65 
66 }// namespace cx
67 
68 #endif /*CXSLICERREPSW_H_*/
vtkImageActorPtr
vtkSmartPointer< class vtkImageActor > vtkImageActorPtr
Definition: vtkForwardDeclarations.h:64
cxRepImpl.h
cx
Namespace for all CustusX production code.
Definition: cx_dev_group_definitions.h:13
cxForwardDeclarations.h
cx::SliceRepSWPtr
boost::shared_ptr< class SliceRepSW > SliceRepSWPtr
Definition: cxForwardDeclarations.h:97
cx::SliceRepSW::getType
virtual QString getType() const
Definition: cxSlicerRepSW.h:46
vtkForwardDeclarations.h
cx::ImagePtr
boost::shared_ptr< class Image > ImagePtr
Definition: cxDicomWidget.h:27
cx::SliceRepSW
Display an image slice in 2D.
Definition: cxSlicerRepSW.h:40
cx::SliceProxyInterfacePtr
boost::shared_ptr< class SliceProxyInterface > SliceProxyInterfacePtr
Definition: cxSlicedImageProxy.h:28
cx::ViewPtr
boost::shared_ptr< class View > ViewPtr
Definition: cxForwardDeclarations.h:110
cx::RepImpl
Default implementation of Rep.
Definition: cxRepImpl.h:42
cx::Indent
Formatting class for debug printing of the ssc library.
Definition: cxIndent.h:28
cx::SlicedImageProxyPtr
boost::shared_ptr< class SlicedImageProxy > SlicedImageProxyPtr
Definition: cxForwardDeclarations.h:89