Medical Imaging Interaction Toolkit  2018.4.99-c4b6bb11
Medical Imaging Interaction Toolkit
mitkPAVolume.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 (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef MITKPHOTOACOUSTIC3dVOLUME_H
14 #define MITKPHOTOACOUSTIC3dVOLUME_H
15 
17 
18 //Includes for smart pointer usage
19 #include <mitkImage.h>
20 #include <itkLightObject.h>
21 
22 namespace mitk
23 {
24  namespace pa
25  {
30  class MITKPHOTOACOUSTICSLIB_EXPORT Volume : public itk::LightObject
31  {
32  public:
33 
34  mitkClassMacroItkParent(Volume, itk::LightObject);
35 
46  static Volume::Pointer New(double* data, unsigned int xDim, unsigned int yDim, unsigned int zDim, double spacing);
47 
48  static Volume::Pointer New(mitk::Image::Pointer image);
49 
61  double GetData(unsigned int x, unsigned int y, unsigned int z);
62 
66  double* GetData() const;
67 
75  void SetData(double data, unsigned int x, unsigned int y, unsigned int z);
76 
81  unsigned int GetXDim();
82 
87  unsigned int GetYDim();
88 
93  unsigned int GetZDim();
94 
98  Image::Pointer AsMitkImage();
99 
105  Volume::Pointer DeepCopy();
106 
111  long long GetIndex(unsigned int x, unsigned int y, unsigned int z);
112 
113  double GetSpacing();
114 
115  void SetSpacing(double spacing);
116 
117  protected:
129  Volume(double* data, unsigned int xDim, unsigned int yDim, unsigned int zDim, double spacing);
131  ~Volume() override;
132 
133  const int NUMBER_OF_SPATIAL_DIMENSIONS = 3;
134 
136 
137  // this data is kept to enable fast access
138  unsigned int m_XDim;
139  unsigned int m_YDim;
140  unsigned int m_ZDim;
142  };
143  }
144 }
145 
146 #endif // MITKPHOTOACOUSTIC3dVOLUME_H
unsigned int m_YDim
Definition: mitkPAVolume.h:139
static vtkSmartPointer< vtkPolyData > DeepCopy(vtkPolyData *other)
Definition: mitkSurface.cpp:20
DataCollection - Class to facilitate loading/accessing structured data.
unsigned int m_ZDim
Definition: mitkPAVolume.h:140
unsigned int m_XDim
Definition: mitkPAVolume.h:138
The Volume class is designed to encapsulate volumetric information and to provide convenience methods...
Definition: mitkPAVolume.h:30
#define mitkClassMacroItkParent(className, SuperClassName)
Definition: mitkCommon.h:49
double * m_FastAccessDataPointer
Definition: mitkPAVolume.h:141
mitk::Image::Pointer image
Image::Pointer m_InternalMitkImage
Definition: mitkPAVolume.h:135
#define MITKPHOTOACOUSTICSLIB_EXPORT