MITK-IGT
IGT Extension of MITK
Loading...
Searching...
No Matches
mitkToFCameraPMDCamCubeDevice.cpp
Go to the documentation of this file.
1/*============================================================================
2
3The Medical Imaging Interaction Toolkit (MITK)
4
5Copyright (c) German Cancer Research Center (DKFZ)
6All rights reserved.
7
8Use of this source code is governed by a 3-clause BSD license that can be
9found in the LICENSE file.
10
11============================================================================*/
13#include "mitkRealTimeClock.h"
14
15#include "itkMultiThreader.h"
16
17
18namespace mitk
19{
21 {
22 m_Controller = ToFCameraPMDCamCubeController::New();
23 }
24
28
29 void ToFCameraPMDCamCubeDevice::SetProperty( const char *propertyKey, BaseProperty* propertyValue )
30 {
31 ToFCameraPMDDevice::SetProperty(propertyKey,propertyValue);
32 this->m_PropertyList->SetProperty(propertyKey, propertyValue);
33
34 ToFCameraPMDCamCubeController::Pointer myController = dynamic_cast<mitk::ToFCameraPMDCamCubeController*>(this->m_Controller.GetPointer());
35
36 bool boolValue = false;
37 GetBoolProperty(propertyKey, boolValue);
38 if (strcmp(propertyKey, "SetFPNCalibration") == 0)
39 {
40 myController->SetFPNCalibration(boolValue);
41 }
42 else if (strcmp(propertyKey, "SetFPPNCalibration") == 0)
43 {
44 myController->SetFPPNCalibration(boolValue);
45 }
46 else if (strcmp(propertyKey, "SetLinearityCalibration") == 0)
47 {
48 myController->SetLinearityCalibration(boolValue);
49 }
50 else if (strcmp(propertyKey, "SetLensCalibration") == 0)
51 {
52 myController->SetLensCalibration(boolValue);
53 }
54 else if (strcmp(propertyKey, "SetExposureMode") == 0)
55 {
56 if (boolValue)
57 {
58 myController->SetExposureMode(1);
59 }
60 else
61 {
62 myController->SetExposureMode(0);
63 }
64 }
65 }
66
67}
PropertyList::Pointer m_PropertyList
a list of the corresponding properties
bool GetBoolProperty(const char *propertyKey, bool &boolValue)
get a bool from the property list
Interface to the Time-of-Flight (ToF) camera PMD CamCube.
virtual void SetProperty(const char *propertyKey, BaseProperty *propertyValue)
set a BaseProperty
virtual void SetProperty(const char *propertyKey, BaseProperty *propertyValue)
set a BaseProperty
ToFCameraPMDController::Pointer m_Controller
corresponding CameraController
IGT Exceptions.
int strcmp(const String &s1, const String &s2)
Definition relates.cpp:14