34 m_DeviceRegistrations.insert(std::make_pair(device.GetPointer(), context->RegisterService(device.GetPointer(),deviceProps)));
40 std::map<ToFCameraDevice*,us::ServiceRegistration<ToFCameraDevice> >::iterator i =
m_DeviceRegistrations.find(device.GetPointer());
43 i->second.Unregister();
59 MITK_WARN <<
"Could not load resource '" << resource.
GetName() <<
"'. CameraIntrinsics are invalid!";
66 TiXmlDocument xmlDocument;
67 resStream >> xmlDocument;
70 TiXmlElement* element = xmlDocument.FirstChildElement();
72 intrinsics->FromXML(element);
80 return module->
GetResource(
"CalibrationFiles/Default_Parameters.xml");
81 MITK_WARN <<
"Loaded Default CameraIntrinsics. Overwrite AbstractToFDeviceFactory::GetIntrinsicsResource() if you want to define your own.";
std::vector< ToFCameraDevice::Pointer > m_Devices
m_Devices A list (vector) containing all connected devices of the respective factory.
std::string GetCurrentDeviceName() override
GetCurrentDeviceName Get the human readable name of the current device. A factory can produce many de...
virtual ToFCameraDevice::Pointer CreateToFCameraDevice()=0
CreateToFCameraDevice Create a new device of the respective factory. E.g. a "KinectFactory" creates a...
CameraIntrinsics::Pointer GetCameraIntrinsics()
Returns the CameraIntrinsics for the cameras created by this factory.
vcl_size_t GetNumberOfDevices()
GetNumberOfDevices Get the number of devices produced by this factory. This function will return the ...
void DisconnectToFDevice(const ToFCameraDevice::Pointer &device)
DisconnectToFDevice Use this method to disconnect a device.
Module * GetModule() const
ModuleResource GetResource(const std::string &path) const
US_UNORDERED_MAP_TYPE< std::string, Any > ServiceProperties
virtual us::ModuleResource GetIntrinsicsResource()
Returns the ModuleResource that contains a xml definition of the CameraIntrinsics.
static ModuleContext * GetModuleContext()
Returns the module context of the calling module.
ToFCameraDevice::Pointer ConnectToFDevice()
ConnectToFDevice Use this method to connect a device.
std::map< ToFCameraDevice *, us::ServiceRegistration< ToFCameraDevice > > m_DeviceRegistrations
m_DeviceRegistrations A map containing all the pairs of device registration numbers and devices...
std::string GetName() const