00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef __frePointSetRegistrationControllerBase_h
00023 #define __frePointSetRegistrationControllerBase_h
00024
00025 #include "freRegistrationProcessorControllerBase.h"
00026 #include "freOptimizerOwnerControllerInterface.h"
00027
00028 namespace FREE
00029 {
00030
00040 freControllerIDMacro(PointSetRegistrationControllerBase, "PointSetRegistrationBase");
00041 template <class TControlledRigidProcessor>
00042 class PointSetRegistrationControllerBase : public RegistrationProcessorControllerBase<TControlledRigidProcessor>, public OptimizerOwnerControllerInterface
00043 {
00044 public:
00045 typedef TControlledRigidProcessor ComponentType;
00046 typedef RegistrationProcessorControllerBase<ComponentType> Superclass;
00047 typedef PointSetRegistrationControllerBase<ComponentType> Self;
00048
00049 typedef typename ComponentType::Pointer ComponentPointer;
00050 typedef typename Superclass::GenericComponentType GenericComponentType;
00051 typedef typename Superclass::GenericComponentPointer GenericComponentPointer;
00052 typedef typename Superclass::GenericMediaPointer GenericMediaPointer;
00053
00054 DeclareParameterMacro(PersistentFinalField);
00055
00056 DeclareMediaIDMacro(fixedPointSet);
00057 DeclareMediaIDMacro(movingPointSet);
00058 DeclareMediaIDMacro(fieldReference);
00059 DeclareMediaIDMacro(finalField);
00060
00061 DeclareMediaIDMacro(finalTransform);
00062 DeclareMediaIDMacro(finalInverseTransform);
00063
00064 itkTypeMacro(PointSetRegistrationControllerBase, RegistrationProcessorControllerBase);
00065
00066 virtual ValidityTag::Pointer GetMediaValidityTagRequirement(const MediaID& mediaID, SessionComponentCache* pComponentCache) const;
00067
00068 virtual bool GetMinimizeToOptimize(const SessionComponentCache* pComponentCache) const;
00069
00070 virtual Parameter::Pointer GetParameter(const SessionComponentCache* pComponentCache,
00071 const std::string& sParameterName) const;
00072 protected:
00073 PointSetRegistrationControllerBase();
00074
00075 virtual void GenerateProfile(CtrlProfile::ControllerProfile& profile,
00076 const SessionComponentCache* pComponentCache,
00077 bool bRegardOldSetup) const;
00078
00079 virtual ComponentPointer BuildMainComponent(ComponentSetup* pComponentSetup,
00080 SessionComponentCache* pComponentCache) const;
00081
00082 virtual void ActualizeMainComponent(ComponentType* pMainComponent,
00083 SessionComponentCache* pComponentCache,
00084 SessionInfo* pSessionInfo,
00085 const unsigned int& iActLevel) const;
00086
00087 virtual GenericComponentType* GetSubComponentCasted(ComponentType* pMainComponent, const ComponentID& compID,
00088 SessionComponentCache* pMainComponentCache) const;
00089 virtual void SetSubComponentCasted(GenericComponentType* pSubComponent, ComponentType* pMainComponent,
00090 const ComponentID compID, SessionComponentCache* pMainComponentCache) const;
00091
00092 virtual GenericMediaPointer GetMediaCasted(const MediaID& mediaID,
00093 ComponentType* pComponent,
00094 SessionComponentCache* pComponentCache,
00095 SessionInfo* pSessionInfo) const;
00096
00097 virtual void SetMediaCasted(const MediaID& mediaID, GenericMediaType* pMedia, ComponentType* pComponent, SessionComponentCache* pComponentCache,
00098 SessionInfo* pSessionInfo) const;
00099
00100 virtual ValidityTag::Pointer GetValidityTagRequirement(const std::string& id, SessionComponentCache* pComponentCache) const;
00101
00102 virtual void ResetMainComponent(SessionComponentCache* pComponentCache,
00103 SessionInfo* pSessionInfo) const;
00104
00105 virtual void ResetSubComponents(SessionComponentCache* pComponentCache,
00106 SessionInfo* pSessionInfo) const;
00107 };
00108
00109 }
00110
00111 #ifndef ITK_MANUAL_INSTANTIATION
00112 #include "frePointSetRegistrationControllerBase.txx"
00113 #endif
00114
00115 #endif