Skip to content

Commit

Permalink
BUG: Add ConstantImageFilter::DynamicThreadedGenerateData
Browse files Browse the repository at this point in the history
Detected by:

  include/itkMetamorphosisImageRegistrationMethodv4.h:74:8: warning: 'ThreadedGenerateData' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]

ThreadedGenerateData has been replace by DynamicThreadedGenerateData in
ITK 5:

  https://github.com/InsightSoftwareConsortium/ITK/blob/master/Documentation/ITK5MigrationGuide.md
  • Loading branch information
thewtex committed Mar 18, 2019
1 parent d9a69dd commit 1bc0599
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions include/itkMetamorphosisImageRegistrationMethodv4.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,17 +71,15 @@ public ImageToImageFilter<TInputImage, TOutputImage>
~ConstantImageFilter(){}

/** Does the real work. */
void ThreadedGenerateData( const typename OutputImageType::RegionType& outputRegionForThread, ThreadIdType threadId)
void DynamicThreadedGenerateData(const typename OutputImageType::RegionType& outputRegionForThread) override
{
ProgressReporter progress(this, threadId, outputRegionForThread.GetNumberOfPixels());
OutputPixelType constant = this->GetConstant();
OutputImageIteratorType it(this->GetOutput(),outputRegionForThread);

while(!it.IsAtEnd())
{
it.Set(constant);
++it;
progress.CompletedPixel();
}
}

Expand Down

0 comments on commit 1bc0599

Please sign in to comment.