00001 /*========================================================================= 00002 00003 Program: F.R.E.E. - flexible registration evaluation engine 00004 Version: v.1.0.0 00005 Date: $Date: 2006/09/01 12:00:00 $ 00006 Module: $RCSfile: freRegistrationProcessEventHandler.h,v $ 00007 Language: C++ 00008 00009 00010 00011 Copyright (c) 2007 Ralf o Floca (Department of Medical Informatics, 00012 Institute for Medical Biometry and Informatics, University of Heidelberg, 00013 Germany). All rights reserved. 00014 See FREECopyright.txt or http://www.mi.med.uni-hd.de/free/copyright.htm 00015 for details. 00016 00017 This software is distributed WITHOUT ANY WARRANTY; without even 00018 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00019 PURPOSE. See the above copyright notices for more information. 00020 00021 =========================================================================*/ 00022 #ifndef __freRegistrationProcessEventHandler_h 00023 #define __freRegistrationProcessEventHandler_h 00024 00025 #include "freRegistrationEvents.h" 00026 #include "freControllerEvents.h" 00027 #include "freSessionComponentCache.h" 00028 #include "freSessionInfo.h" 00029 00030 namespace FREE 00031 { 00032 00047 template <class TRegistrationProcessor> 00048 class RegistrationProcessEventHandler : public itk::LightObject 00049 { 00050 public: 00051 typedef RegistrationProcessEventHandler<TRegistrationProcessor> Self; 00052 typedef itk::SmartPointer<RegistrationProcessEventHandler> Pointer; 00053 typedef TRegistrationProcessor RegistrationProcessorType; 00054 00055 itkNewMacro(RegistrationProcessEventHandler); 00056 itkTypeMacro(RegistrationProcessEventHandler,itk::LightObject); 00057 00058 void SetSessionInfo(SessionInfo* pSessionInfo); 00059 void SetComponentCache(SessionComponentCache* pCache); 00060 00061 void SetRegistrationEntry(StatisticEntry* pEntry); 00062 StatisticEntry* GetRegistrationEntry(); 00063 StatisticEntry* GetLevelEntry(); 00064 StatisticEntry* GetIterationEntry(); 00065 00066 protected: 00067 RegistrationProcessEventHandler(); 00068 00070 typename IterationEvent<Self>::Pointer m_IterationEvent; 00072 typename LevelEvent<Self>::Pointer m_LevelEvent; 00074 typename RegistrationProgressEvent<Self>::Pointer m_RegistrationProgressEvent; 00075 00076 SessionInfo* m_pSessionInfo; 00077 00078 SessionComponentCache* m_pCache; 00079 00080 RegistrationProcessorType* m_pProcessor; 00081 00082 StatisticEntry* m_pRegistrationEntry; 00083 StatisticEntry* m_pLevelEntry; 00084 StatisticEntry* m_pIterationEntry; 00085 00093 void OnNextLevel(const unsigned int iLevel, void* pSender, long threadID = 0); 00094 00103 void OnNextIteration(const long lIteration, Statistics* pStatistic, void* pSender, long threadID = 0); 00104 00113 void OnRegistrationProgressEvent(const RegistrationStatusType status, 00114 const std::string sComment, void* pSender, 00115 long threadID = 0); 00116 00117 }; 00118 00119 } //end of namespace free 00120 00121 #ifndef ITK_MANUAL_INSTANTIATION 00122 #include "freRegistrationProcessEventHandler.txx" 00123 #endif 00124 00125 #endif
1.5.3 written by Dimitri van Heesch,
© 1997-2000