Package org.itk.simple
Class ShrinkImageFilter
java.lang.Object
org.itk.simple.ProcessObject
org.itk.simple.ImageFilter
org.itk.simple.ShrinkImageFilter
Reduce the size of an image by an integer factor in each dimension.
ShrinkImageFilter reduces the size of an image by an integer factor in each dimension.
The algorithm implemented is a simple subsample. The output image size
in each dimension is given by:
outputSize[j] = max( std::floor(inputSize[j]/shrinkFactor[j]), 1 );
NOTE: The physical centers of the input and output will be the same.
Because of this, the Origin of the output may not be the same as the
Origin of the input. Since this filter produces an image which is a
different resolution, origin and with different pixel spacing than its
input image, it needs to override several of the methods defined in ProcessObject in order to properly manage the pipeline execution model. In
particular, this filter overrides ProcessObject::GenerateInputRequestedRegion() and ProcessObject::GenerateOutputInformation() .
This filter is implemented as a multithreaded filter. It provides a
DynamicThreadedGenerateData() method for its implementation.
See:
itk::simple::Shrink for the procedural interface
itk::ShrinkImageFilter for the Doxygen on the original ITK class.
C++ includes: sitkShrinkImageFilter.h
-
Field Summary
Fields inherited from class org.itk.simple.ProcessObject
swigCMemOwn
-
Constructor Summary
ConstructorsModifierConstructorDescriptionitk::simple::ShrinkImageFilter::ShrinkImageFilter() Default Constructor that takes no arguments and initializes default parametersprotected
ShrinkImageFilter
(long cPtr, boolean cMemoryOwn) -
Method Summary
Modifier and TypeMethodDescriptionvoid
delete()
virtual itk::simple::ShrinkImageFilter::~ShrinkImageFilter() DestructorImage itk::simple::ShrinkImageFilter::Execute(const Image &image1) Execute the filter on the input imageprotected void
finalize()
protected static long
getCPtr
(ShrinkImageFilter obj) getName()
std::string itk::simple::ShrinkImageFilter::GetName() const Name of this classstd::vector<unsigned int> itk::simple::ShrinkImageFilter::GetShrinkFactors() const Get the shrink factors.void
setShrinkFactor
(long s) Self& itk::simple::ShrinkImageFilter::SetShrinkFactor(unsigned int s) Custom public declarationsvoid
setShrinkFactors
(VectorUInt32 ShrinkFactors) Self& itk::simple::ShrinkImageFilter::SetShrinkFactors(std::vector< unsigned int > ShrinkFactors) Set the shrink factors.protected static long
toString()
std::string itk::simple::ShrinkImageFilter::ToString() const Print ourselves outMethods inherited from class org.itk.simple.ImageFilter
getCPtr, swigRelease
Methods inherited from class org.itk.simple.ProcessObject
abort, addCommand, debugOff, debugOn, getCPtr, getDebug, getGlobalDefaultCoordinateTolerance, getGlobalDefaultDebug, getGlobalDefaultDirectionTolerance, getGlobalDefaultNumberOfThreads, getGlobalDefaultThreader, getGlobalWarningDisplay, getNumberOfThreads, getNumberOfWorkUnits, getProgress, globalDefaultDebugOff, globalDefaultDebugOn, globalWarningDisplayOff, globalWarningDisplayOn, hasCommand, removeAllCommands, setDebug, setGlobalDefaultCoordinateTolerance, setGlobalDefaultDebug, setGlobalDefaultDirectionTolerance, setGlobalDefaultNumberOfThreads, setGlobalDefaultThreader, setGlobalWarningDisplay, setNumberOfThreads, setNumberOfWorkUnits, swigRelease
-
Constructor Details
-
ShrinkImageFilter
protected ShrinkImageFilter(long cPtr, boolean cMemoryOwn) -
ShrinkImageFilter
public ShrinkImageFilter()itk::simple::ShrinkImageFilter::ShrinkImageFilter() Default Constructor that takes no arguments and initializes default parameters
-
-
Method Details
-
getCPtr
-
swigRelease
-
finalize
protected void finalize()- Overrides:
finalize
in classImageFilter
-
delete
public void delete()virtual itk::simple::ShrinkImageFilter::~ShrinkImageFilter() Destructor- Overrides:
delete
in classImageFilter
-
setShrinkFactor
public void setShrinkFactor(long s) Self& itk::simple::ShrinkImageFilter::SetShrinkFactor(unsigned int s) Custom public declarations -
setShrinkFactors
Self& itk::simple::ShrinkImageFilter::SetShrinkFactors(std::vector< unsigned int > ShrinkFactors) Set the shrink factors. Values are clamped to a minimum value of 1. Default is 1 for all dimensions. -
getShrinkFactors
std::vector<unsigned int> itk::simple::ShrinkImageFilter::GetShrinkFactors() const Get the shrink factors. -
getName
std::string itk::simple::ShrinkImageFilter::GetName() const Name of this class- Overrides:
getName
in classProcessObject
-
toString
std::string itk::simple::ShrinkImageFilter::ToString() const Print ourselves out- Overrides:
toString
in classProcessObject
-
execute
Image itk::simple::ShrinkImageFilter::Execute(const Image &image1) Execute the filter on the input image
-