14 #include <boost/bind.hpp>
15 #include <ctkPluginContext.h>
24 mPluginContext(context),
27 this->initServiceListener();
30 void RegistrationServiceProxy::initServiceListener()
34 boost::bind(&RegistrationServiceProxy::onServiceAdded,
this, _1),
36 boost::bind(&RegistrationServiceProxy::onServiceRemoved,
this, _1)
38 mServiceListener->open();
40 void RegistrationServiceProxy::onServiceAdded(RegistrationService* service)
42 mRegistrationService.reset(service, null_deleter());
45 if(mRegistrationService->isNull())
46 reportWarning(
"RegistrationServiceProxy::onServiceAdded mRegistrationService->isNull()");
52 void RegistrationServiceProxy::onServiceRemoved(RegistrationService *service)
64 mRegistrationService->setMovingData(data);
70 mRegistrationService->setFixedData(data);
75 return mRegistrationService->getMovingData();
80 return mRegistrationService->getFixedData();
85 return mRegistrationService->doPatientRegistration();
90 return mRegistrationService->doFastRegistration_Translation();
95 return mRegistrationService->doFastRegistration_Orientation(tMtm, prMt);
100 return mRegistrationService->doImageRegistration(translationOnly);
105 mRegistrationService->addImage2ImageRegistration(delta_pre_rMd, description);
110 mRegistrationService->updateImage2ImageRegistration(delta_pre_rMd, description);
115 mRegistrationService->addPatientRegistration( rMpr_new, description);
120 mRegistrationService->updatePatientRegistration( rMpr_new, description);
125 mRegistrationService->applyPatientOrientation(tMtm, prMt);
130 return mRegistrationService->getLastRegistrationTime();
135 mRegistrationService->setLastRegistrationTime(time);
140 return mRegistrationService->isNull();