11 #ifndef itkPluginFilterWatcher_h 12 #define itkPluginFilterWatcher_h 15 #include <ModuleProcessInformation.h> 18 #include <itkSimpleFilterWatcher.h> 32 const char *comment=
"",
33 ModuleProcessInformation *inf=0,
34 double fraction = 1.0,
36 : SimpleFilterWatcher(o, comment)
49 if (this->GetProcess())
51 this->SetSteps( this->GetSteps()+1 );
52 if (!this->GetQuiet())
57 this->GetComment().c_str(), 1023);
67 this->GetTimeProbe().Stop();
69 = this->GetTimeProbe().GetMean()
70 * this->GetTimeProbe().GetNumberOfStops();
76 this->GetTimeProbe().Start();
80 this->GetProcess()->AbortGenerateDataOn();
93 std::cout <<
"<filter-progress>" 95 <<
"</filter-progress>" 99 std::cout <<
"<filter-stage-progress>" 100 << this->GetProcess()->GetProgress()
101 <<
"</filter-stage-progress>" 104 std::cout << std::flush;
115 this->SetIterations(0);
116 this->GetTimeProbe().Start();
117 if (!this->GetQuiet())
124 this->GetComment().c_str(), 1023);
134 std::cout <<
"<filter-start>" 136 std::cout <<
"<filter-name>" 137 << (this->GetProcess()
138 ? this->GetProcess()->GetNameOfClass() :
"None")
141 std::cout <<
"<filter-comment>" 142 <<
" \"" << this->GetComment() <<
"\" " 143 <<
"</filter-comment>" 145 std::cout <<
"</filter-start>" 147 std::cout << std::flush;
156 this->GetTimeProbe().Stop();
157 if (!this->GetQuiet())
165 = this->GetTimeProbe().GetMean()
166 * this->GetTimeProbe().GetNumberOfStops();
176 std::cout <<
"<filter-end>" 178 std::cout <<
"<filter-name>" 179 << (this->GetProcess()
180 ? this->GetProcess()->GetNameOfClass() :
"None")
183 std::cout <<
"<filter-time>" 184 << this->GetTimeProbe().GetMean()
187 std::cout <<
"</filter-end>";
188 std::cout << std::flush;
virtual void StartFilter()
Simplified inverse ITK transforms.
virtual void ShowProgress()
ModuleProcessInformation * m_ProcessInformation
PluginFilterWatcher(itk::ProcessObject *o, const char *comment="", ModuleProcessInformation *inf=0, double fraction=1.0, double start=0.0)
Simple mechanism for monitoring the pipeline events of a filter and reporting these events to std::co...