Package org.itk.simple
Class CompositeTransform
java.lang.Object
org.itk.simple.Transform
org.itk.simple.CompositeTransform
This class contains a stack of transforms and concatenates them by
composition.
The transforms are composed in reverse order with the back being applied first: $ T_0 o T_1 = T_0(T_1(x)) $ Transforms are stored in a queue, in the following order: $ T_0, T_1, ... , T_N-1 $
Transforms are added via AddTransform(). This adds the transforms to the back of the queue.
The only parameters of the transform at the back of the queue are
exposed and optimizable for registration.
Inverse: The inverse transform is created by retrieving the inverse
from each sub transform and adding them to a composite transform in
reverse order. The m_TransformsToOptimizeFlags is copied in reverse
for the inverse.
See:
itk::CompositeTransform
C++ includes: sitkCompositeTransform.h
-
Field Summary
Fields inherited from class org.itk.simple.Transform
swigCMemOwn
-
Constructor Summary
ConstructorsModifierConstructorDescriptionCompositeTransform
(long dimensions) itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform.protected
CompositeTransform
(long cPtr, boolean cMemoryOwn) itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform.CompositeTransform
(Transform arg0) itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform.itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Self& itk::simple::CompositeTransform::AddTransform(Transform t) Add a transform to the back of the stack.void
void itk::simple::CompositeTransform::ClearTransforms() Remove all transforms from the stack.void
delete()
itk::simple::CompositeTransform::~CompositeTransform() overrideprotected void
finalize()
void
Self& itk::simple::CompositeTransform::FlattenTransform() Removes nested composite transforms.Transform itk::simple::CompositeTransform::GetBackTransform() Get a copy of the back transform.protected static long
getName()
std::string itk::simple::CompositeTransform::GetName() const override Name of this classgetNthTransform
(long n) Transform itk::simple::CompositeTransform::GetNthTransform(unsigned int n) Get a copy of a transform in the stack.long
unsigned int itk::simple::CompositeTransform::GetNumberOfTransforms() const The number of transforms in the stack.void
void itk::simple::CompositeTransform::RemoveTransform() Remove the active transform at the back.protected static long
Methods inherited from class org.itk.simple.Transform
getCPtr, getDimension, getFixedParameters, getInverse, getITKBase, getNumberOfFixedParameters, getNumberOfParameters, getParameters, getTransformEnum, isLinear, makeUnique, setFixedParameters, setIdentity, setInverse, setParameters, swigRelease, toString, transformPoint, transformVector, writeTransform
-
Constructor Details
-
CompositeTransform
protected CompositeTransform(long cPtr, boolean cMemoryOwn) -
CompositeTransform
public CompositeTransform(long dimensions) itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform. The created CompositeTransform is initialized with zero transforms. Additional transforms of dimensions can be added. -
CompositeTransform
itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform. The created CompositeTransform is initialized with zero transforms. Additional transforms of dimensions can be added. -
CompositeTransform
itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform. The created CompositeTransform is initialized with zero transforms. Additional transforms of dimensions can be added. -
CompositeTransform
itk::simple::CompositeTransform::CompositeTransform(unsigned int dimensions) Construct an empty CompositeTransform. The created CompositeTransform is initialized with zero transforms. Additional transforms of dimensions can be added.
-
-
Method Details
-
getCPtr
-
swigRelease
-
finalize
protected void finalize() -
delete
public void delete()itk::simple::CompositeTransform::~CompositeTransform() override -
getName
std::string itk::simple::CompositeTransform::GetName() const override Name of this class -
flattenTransform
public void flattenTransform()Self& itk::simple::CompositeTransform::FlattenTransform() Removes nested composite transforms. If this transform contains additional composite transforms, then these nested composite transformed are removed, while preserving the order of the regular transforms and transferring ownership to the parent CompositeTransform. Nested composite transform may not be written to a file. -
addTransform
Self& itk::simple::CompositeTransform::AddTransform(Transform t) Add a transform to the back of the stack. A deep-copy of the transform is performed. The added transform will have the optimizable parameters, while the other parameters are part of the fixed parameters. -
getNumberOfTransforms
public long getNumberOfTransforms()unsigned int itk::simple::CompositeTransform::GetNumberOfTransforms() const The number of transforms in the stack. -
clearTransforms
public void clearTransforms()void itk::simple::CompositeTransform::ClearTransforms() Remove all transforms from the stack. -
removeTransform
public void removeTransform()void itk::simple::CompositeTransform::RemoveTransform() Remove the active transform at the back. If the stack is empty an exception will be thrown. -
getBackTransform
Transform itk::simple::CompositeTransform::GetBackTransform() Get a copy of the back transform. If the stack is empty an exception will be thrown. -
getNthTransform
Transform itk::simple::CompositeTransform::GetNthTransform(unsigned int n) Get a copy of a transform in the stack. If n is equal or greater than the number of transforms, then an exception will be thrown.
-