Medical Imaging Interaction Toolkit  2023.04.00
Medical Imaging Interaction Toolkit
mitkToFCameraPMDRawDataDevice.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 #ifndef mitkToFCameraPMDRawDataDevice_h
13 #define mitkToFCameraPMDRawDataDevice_h
14 
15 #include <MitkPMDExports.h>
16 #include "mitkToFCameraDevice.h"
19 
20 namespace mitk
21 {
30  class MITKPMD_EXPORT ToFCameraPMDRawDataDevice : public ToFCameraDevice
31  {
32  public:
33 
35 
36  itkFactorylessNewMacro(Self);
37 
38  itkCloneMacro(Self);
39 
40  itkSetMacro(ChannelSize, int);
41  itkGetMacro(ChannelSize, int);
45  virtual bool OnConnectCamera();
49  virtual bool DisconnectCamera();
54  virtual void StartCamera();
58  virtual void StopCamera();
62  virtual void UpdateCamera();
66  virtual bool IsCameraActive();
73  virtual void GetAmplitudes(float* amplitudeArray, int& imageSequence);
79  virtual void GetIntensities(float* intensityArray, int& imageSequence);
85  virtual void GetDistances(float* distanceArray, int& imageSequence);
96  virtual void GetAllImages(float* distanceArray, float* amplitudeArray, float* intensityArray, char* sourceDataArray,
97  int requiredImageSequence, int& capturedImageSequence, unsigned char* rgbDataArray=nullptr);
101  ToFCameraPMDController::Pointer GetController();
102 
103  virtual void GetChannelSourceData(short* /*sourceData*/, vtkShortArray* /*vtkChannelArray*/ ){};
104 
108  virtual void SetProperty( const char *propertyKey, BaseProperty* propertyValue );
109 
110  protected:
111 
113 
115 
119  virtual void AllocateSourceData();
120 
124  virtual void CleanUpSourceData();
125 
129  virtual void AllocatePixelArrays();
133  virtual void CleanupPixelArrays();
137  static ITK_THREAD_RETURN_TYPE Acquire(void* pInfoStruct);
138 
142  void GetNextPos();
143 
152  void XYAxisFlipImage( float* imageData, float* &flippedData, int xAxis, int yAxis, int dimension = 1 );
153 
154  //member variables
155  ToFCameraPMDController::Pointer m_Controller;
156  ThreadedToFRawDataReconstruction::Pointer m_RawDataSource;
160  unsigned int m_OriginControllerWidth;
162 
163  private:
164  int m_ChannelSize;
165 
166  };
167 } //END mitk namespace
168 #endif
mitk::ToFCameraPMDRawDataDevice::m_OriginControllerWidth
unsigned int m_OriginControllerWidth
holds the original controller width
Definition: mitkToFCameraPMDRawDataDevice.h:160
mitk::ToFCameraPMDRawDataDevice::m_SourceDataBuffer
char ** m_SourceDataBuffer
buffer holding the last acquired images
Definition: mitkToFCameraPMDRawDataDevice.h:157
mitk::BaseProperty
Abstract base class for properties.
Definition: mitkBaseProperty.h:35
mitkToFCameraPMDController.h
mitk::ToFCameraPMDRawDataDevice::m_OriginControllerHeight
unsigned int m_OriginControllerHeight
holds the original controller height
Definition: mitkToFCameraPMDRawDataDevice.h:161
mitk::ToFCameraPMDRawDataDevice::m_RawDataSource
ThreadedToFRawDataReconstruction::Pointer m_RawDataSource
Definition: mitkToFCameraPMDRawDataDevice.h:156
mitk
DataCollection - Class to facilitate loading/accessing structured data.
Definition: RenderingTests.dox:1
mitk::ToFCameraPMDRawDataDevice::m_ShortSourceData
short * m_ShortSourceData
array holding the current PMD raw data
Definition: mitkToFCameraPMDRawDataDevice.h:159
mitk::ToFCameraPMDRawDataDevice
Interface for all representations of PMD ToF devices. ToFCameraPMDDevice internally holds an instance...
Definition: mitkToFCameraPMDRawDataDevice.h:30
mitk::ToFCameraPMDRawDataDevice::m_SourceDataArray
char * m_SourceDataArray
array holding the current PMD source data
Definition: mitkToFCameraPMDRawDataDevice.h:158
mitk::ToFCameraPMDRawDataDevice::m_Controller
ToFCameraPMDController::Pointer m_Controller
corresponding CameraController
Definition: mitkToFCameraPMDRawDataDevice.h:155
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
mitk::ToFCameraDevice
Virtual interface and base class for all Time-of-Flight devices.
Definition: mitkToFCameraDevice.h:37
mitkToFCameraDevice.h
mitk::ToFCameraPMDRawDataDevice::GetChannelSourceData
virtual void GetChannelSourceData(short *, vtkShortArray *)
Definition: mitkToFCameraPMDRawDataDevice.h:103
mitkThreadedToFRawDataReconstruction.h