Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
Virtual interface and base class for all MESA Time-of-Flight devices. Wraps MESA API provided in library Provides methods for accessing current distance, amplitude, intensity and raw data. Allows to set parameters like modulation frequency and integration time. More...
#include <mitkToFCameraMESAController.h>
Public Member Functions | |
mitkClassMacroItkParent (ToFCameraMESAController, itk::Object) | |
virtual bool | OpenCameraConnection ()=0 |
opens a connection to the ToF camera. Has to be implemented by the sub class More... | |
virtual bool | CloseCameraConnection () |
closes the connection to the camera More... | |
virtual bool | GetAmplitudes (float *amplitudeArray) |
Gets the current amplitude array from the device. More... | |
virtual bool | GetIntensities (float *intensityArray) |
Gets the current intensity array from the device. More... | |
virtual bool | GetDistances (float *distanceArray) |
Gets the current distance array from the device. More... | |
virtual bool | UpdateCamera () |
calls update on the camera -> a new ToF-image is aquired More... | |
virtual int | GetModulationFrequency ()=0 |
Returns the currently set modulation frequency. More... | |
virtual int | SetModulationFrequency (unsigned int modulationFrequency)=0 |
Sets the modulation frequency of the ToF device. The method automatically calculates a valid value from the given frequency to make sure that only valid frequencies are used. More... | |
virtual int | GetIntegrationTime ()=0 |
Returns the currently set integration time. More... | |
virtual int | SetIntegrationTime (unsigned int integrationTime)=0 |
Sets the integration time of the ToF device. The method automatically calculates a valid value from the given integration time to make sure that only valid times are used. More... | |
virtual void | SetInputFileName (std::string inputFileName) |
set input file name used by MESA player classes More... | |
virtual unsigned int | GetCaptureWidth () |
Access the resolution of the image in x direction. More... | |
virtual unsigned int | GetCaptureHeight () |
Access the resolution of the image in y direction. More... | |
Protected Member Functions | |
ToFCameraMESAController () | |
~ToFCameraMESAController () | |
bool | ErrorText (int error) |
Method printing the current error message to the console and returning whether the previous command was successful. More... | |
Protected Attributes | |
char | m_MESAError [128] |
member holding the current error text More... | |
int | m_MESARes |
holds the current result message provided by MESA More... | |
int | m_PixelNumber |
holds the number of pixels contained in the image More... | |
int | m_NumberOfBytes |
holds the number of bytes contained in the image More... | |
unsigned int | m_CaptureWidth |
holds the width of the image in pixel More... | |
unsigned int | m_CaptureHeight |
holds the height of the image in pixel More... | |
int | m_NumImg |
holds the number of images the camera provided (distance, intensity, etc) More... | |
float | m_MaxRangeFactor |
holds the factor to calculate the real distance depends on the modulation frequency More... | |
bool | m_ConnectionCheck |
flag showing whether the camera is connected (true) or not (false) More... | |
std::string | m_InputFileName |
input file name used by MESA player classes More... | |
Virtual interface and base class for all MESA Time-of-Flight devices. Wraps MESA API provided in library Provides methods for accessing current distance, amplitude, intensity and raw data. Allows to set parameters like modulation frequency and integration time.
Definition at line 34 of file mitkToFCameraMESAController.h.
|
protected |
Definition at line 24 of file mitkToFCameraMESAController.cpp.
|
protected |
Definition at line 30 of file mitkToFCameraMESAController.cpp.
|
virtual |
closes the connection to the camera
Definition at line 34 of file mitkToFCameraMESAController.cpp.
References ErrorText(), m_ConnectionCheck, m_MESAHandle, and m_MESARes.
|
protected |
Method printing the current error message to the console and returning whether the previous command was successful.
error | error number returned by the MESA function |
Definition at line 42 of file mitkToFCameraMESAController.cpp.
Referenced by CloseCameraConnection(), and mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
virtual |
Gets the current amplitude array from the device.
amplitudeArray | float array where the amplitude data will be saved |
Definition at line 61 of file mitkToFCameraMESAController.cpp.
References m_MESAHandle, and m_PixelNumber.
|
virtual |
Access the resolution of the image in y direction.
|
virtual |
Access the resolution of the image in x direction.
|
virtual |
Gets the current distance array from the device.
distanceArray | float array where the distance data will be saved |
Definition at line 92 of file mitkToFCameraMESAController.cpp.
References m_MaxRangeFactor, m_MESAHandle, and m_PixelNumber.
|
pure virtual |
Returns the currently set integration time.
Implemented in mitk::ToFCameraMESASR4000Controller.
|
virtual |
Gets the current intensity array from the device.
intensityArray | float array where the intensity data will be saved |
Definition at line 81 of file mitkToFCameraMESAController.cpp.
References m_MESAHandle, and m_PixelNumber.
|
pure virtual |
Returns the currently set modulation frequency.
Implemented in mitk::ToFCameraMESASR4000Controller.
mitk::ToFCameraMESAController::mitkClassMacroItkParent | ( | ToFCameraMESAController | , |
itk::Object | |||
) |
|
pure virtual |
opens a connection to the ToF camera. Has to be implemented by the sub class
Implemented in mitk::ToFCameraMESASR4000Controller.
|
virtual |
set input file name used by MESA player classes
Definition at line 119 of file mitkToFCameraMESAController.cpp.
References m_InputFileName.
|
pure virtual |
Sets the integration time of the ToF device. The method automatically calculates a valid value from the given integration time to make sure that only valid times are used.
integrationTime | integration time |
Implemented in mitk::ToFCameraMESASR4000Controller.
|
pure virtual |
Sets the modulation frequency of the ToF device. The method automatically calculates a valid value from the given frequency to make sure that only valid frequencies are used.
modulationFrequency | modulation frequency |
Implemented in mitk::ToFCameraMESASR4000Controller.
|
virtual |
calls update on the camera -> a new ToF-image is aquired
Definition at line 54 of file mitkToFCameraMESAController.cpp.
References m_MESAHandle, and m_MESARes.
|
protected |
holds the height of the image in pixel
Definition at line 127 of file mitkToFCameraMESAController.h.
Referenced by mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
protected |
holds the width of the image in pixel
Definition at line 126 of file mitkToFCameraMESAController.h.
Referenced by mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
protected |
flag showing whether the camera is connected (true) or not (false)
Definition at line 133 of file mitkToFCameraMESAController.h.
Referenced by CloseCameraConnection(), and mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
protected |
input file name used by MESA player classes
Definition at line 135 of file mitkToFCameraMESAController.h.
Referenced by SetInputFileName().
|
protected |
holds the factor to calculate the real distance depends on the modulation frequency
Definition at line 131 of file mitkToFCameraMESAController.h.
Referenced by GetDistances(), mitk::ToFCameraMESASR4000Controller::GetModulationFrequency(), mitk::ToFCameraMESASR4000Controller::OpenCameraConnection(), and mitk::ToFCameraMESASR4000Controller::SetModulationFrequency().
|
protected |
member holding the current error text
Definition at line 121 of file mitkToFCameraMESAController.h.
|
protected |
holds the current result message provided by MESA
Definition at line 122 of file mitkToFCameraMESAController.h.
Referenced by CloseCameraConnection(), mitk::ToFCameraMESASR4000Controller::OpenCameraConnection(), mitk::ToFCameraMESASR4000Controller::SetANF(), mitk::ToFCameraMESASR4000Controller::SetConvGray(), mitk::ToFCameraMESASR4000Controller::SetFPN(), mitk::ToFCameraMESASR4000Controller::SetIntegrationTime(), mitk::ToFCameraMESASR4000Controller::SetMedian(), mitk::ToFCameraMESASR4000Controller::SetModulationFrequency(), and UpdateCamera().
|
protected |
holds the number of bytes contained in the image
Definition at line 125 of file mitkToFCameraMESAController.h.
Referenced by mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
protected |
holds the number of images the camera provided (distance, intensity, etc)
Definition at line 129 of file mitkToFCameraMESAController.h.
Referenced by mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().
|
protected |
holds the number of pixels contained in the image
Definition at line 124 of file mitkToFCameraMESAController.h.
Referenced by GetAmplitudes(), GetDistances(), GetIntensities(), and mitk::ToFCameraMESASR4000Controller::OpenCameraConnection().