Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkAffineTransform.h File Reference

Go to the source code of this file.

Namespaces

namespace  itk

Defines

#define ITK_TEMPLATE_AffineTransform(_, EXPORT, x, y)

Functions

*Affine transformation of
a vector 
space (e.g.space coordinates)**This class allows the definition and manipulation of affine *transformations of an n-dimensional affine space(and its *associated vector space) onto itself.One common use is to define *and manipulate Euclidean coordinate transformations in two and *three dimensions
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More A can
also define anisotropic scaling
and *shearing transformations
Any good textbook on computer
graphics *will discuss coordinate
transformations in more detail
Several of *the methods in
this class are designed for
this purpose and use the
*language appropriate to coordinate
conversions **Any two affine
transformations may be composed
and the result is *another
affine transformation the
order is important *Given
two affine transformations
T1 and we will say that *precomposing
T1 with T2 yields the transformation
which applies *T1 to the and
then applies T2 to that result
to obtain the *target we will
say that postcomposing T1
with T2 *yields the transformation
which applies T2 to the and
then *applies T1 to that result
to obtain the 
target (Whether T1 or T2 *comes first lexicographically depends on whether you choose to *write mappings from right-to-left or vice versa;we avoid the whole *problem by referring to the order of application rather than the *textual order.)**There are two template parameters for this class

Variables

an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this
application
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More A can
also define anisotropic scaling
and *shearing transformations
Any good textbook on computer
graphics *will discuss coordinate
transformations in more detail
Several of *the methods in
this class are designed for
this purpose and use the
*language appropriate to coordinate
conversions **Any two affine
transformations may be composed
and the result is *another
affine transformation the
order is important *Given
two affine transformations
T1 and we will say that *precomposing
T1 with T2 yields the transformation
which applies *T1 to the and
then applies T2 to that result
to obtain the *target 
Conversely
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target 
coordinates
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More 
generally
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More A can
also define anisotropic scaling
and *shearing transformations
Any good textbook on computer
graphics *will discuss coordinate
transformations in more detail
Several of *the methods in
this class are designed for
this purpose and use the
*language appropriate to coordinate
conversions **Any two affine
transformations may be composed
and the result is *another
affine transformation 
However
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
point
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More A can
also define anisotropic scaling
and *shearing transformations
Any good textbook on computer
graphics *will discuss coordinate
transformations in more detail
Several of *the methods in
this class are designed for
this purpose and use the
*language appropriate to coordinate
conversions **Any two affine
transformations may be composed
and the result is *another
affine transformation the
order is important *Given
two affine transformations
T1 and we will say that *precomposing
T1 with T2 yields the transformation
which applies *T1 to the 
source
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the and
b *defines the translation
of the origin from the source
to the *target More A can
also define anisotropic scaling
and *shearing transformations
Any good textbook on computer
graphics *will discuss coordinate
transformations in more detail
Several of *the methods in
this class are designed for
this purpose and use the
*language appropriate to coordinate
conversions **Any two affine
transformations may be composed
and the result is *another
affine transformation the
order is important *Given
two affine transformations
T1 and 
T2
an object of type Vector transforms
as *a vector **One common
use of affine transformations
is to define coordinate *conversions
in two and three dimensional
space In this x is a two or
three dimensional vector containing
the *source coordinates of
a y is a vector containing
the *target the matrix A defines
the scaling and rotation
*of the coordinate systems
from the source to the 
target
*Affine transformation of
a vector but other uses are
possible as well **An affine
transformation is defined
mathematically as a linear
*transformation plus a constant
offset If A is a constant
n x n *matrix and b is a constant
vector
*Affine transformation of
a vector but other uses are
possible as well **An affine
transformation is defined
mathematically as a linear
*transformation plus a constant
offset If A is a constant
n x n *matrix and b is a constant
n then 
y


Define Documentation

#define ITK_TEMPLATE_AffineTransform _,
EXPORT,
x,
y   ) 
 

Value:

namespace itk { \
  _(2(class EXPORT AffineTransform< ITK_TEMPLATE_2 x >)) \
  namespace Templates { typedef AffineTransform< ITK_TEMPLATE_2 x > AffineTransform##y; } \
  }

Definition at line 316 of file itkAffineTransform.h.


Function Documentation

* Affine transformation of a vector itk::space e.g.space  coordinates  ) 
 

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the and b* defines the translation of the origin from the source to the* target More A can also define anisotropic scaling and* shearing transformations Any good textbook on computer graphics* will discuss coordinate transformations in more detail Several of* the methods in this class are designed for this purpose and use the* language appropriate to coordinate conversions* * Any two affine transformations may be composed and the result is* another affine transformation the order is important* Given two affine transformations T1 and we will say that* precomposing T1 with T2 yields the transformation which applies* T1 to the and then applies T2 to that result to obtain the* target we will say that postcomposing T1 with T2* yields the transformation which applies T2 to the and then* applies T1 to that result to obtain the itk::target Whether T1 or T2 *comes first lexicographically depends on whether you choose to *write mappings from right-to-left or vice versa;we avoid the whole *problem by referring to the order of application rather than the *textual  order.  ) 
 

Standard typedefs

Run-time type information (and related methods).

New macro for creation of through a Smart Pointer

Dimension of the domain space.

Parameters Type

Compose affine transformation with a translation

This method modifies self to include a translation of the origin. The translation is precomposed with self if pre is true, and postcomposed otherwise. This updates Translation based on current center.

Compose affine transformation with a scaling

This method modifies self to magnify the source by a given factor along each axis. If all factors are the same, or only a single factor is given, then the scaling is isotropic; otherwise it is anisotropic. If an odd number of factors are negative, then the parity of the image changes. If any of the factors is zero, then the transformation becomes a projection and is not invertible. The scaling is precomposed with self if pre is true, and postcomposed otherwise. Note that the scaling is applied centered at the origin.

Compose affine transformation with an elementary rotation

This method composes self with a rotation that affects two specified axes, replacing the current value of self. The rotation angle is in radians. The axis of rotation goes through the origin. The transformation is given by

y[axis1] = vcl_cos(angle)*x[axis1] + vcl_sin(angle)*x[axis2] y[axis2] = -sin(angle)*x[axis1] + vcl_cos(angle)*x[axis2].

All coordinates other than axis1 and axis2 are unchanged; a rotation of pi/2 radians will carry +axis1 into +axis2. The rotation is precomposed with self if pre is true, and postcomposed otherwise. Note that the rotation is applied centered at the origin.

Compose 2D affine transformation with a rotation

This method composes self, which must be a 2D affine transformation, with a clockwise rotation through a given angle in radians. The center of rotation is the origin. The rotation is precomposed with self if pre is true, and postcomposed otherwise. Note that the rotation is applied centered at the origin.

Warning:
Only to be use in two dimensions
Todo:
Find a way to generate a compile-time error is this is used with NDimensions != 2.
Compose 3D affine transformation with a rotation

This method composes self, which must be a 3D affine transformation, with a clockwise rotation around a specified axis. The rotation angle is in radians; the axis of rotation goes through the origin. The rotation is precomposed with self if pre is true, and postcomposed otherwise. Note that the rotation is applied centered at the origin.

Warning:
Only to be used in dimension 3
Todo:
Find a way to generate a compile-time error is this is used with NDimensions != 3.
Compose affine transformation with a shear

This method composes self with a shear transformation, replacing the original contents of self. The shear is precomposed with self if pre is true, and postcomposed otherwise. The transformation is given by

y[axis1] = x[axis1] + coef*x[axis2] y[axis2] = x[axis2].

Note that the shear is applied centered at the origin.

Back transform by an affine transformation

This method finds the point or vector that maps to a given point or vector under the affine transformation defined by self. If no such point exists, an exception is thrown.

Deprecated:
Please use GetInverseTransform and then call the forward transform function
Back transform a point by an affine transform

This method finds the point that maps to a given point under the affine transformation defined by self. If no such point exists, an exception is thrown. The returned value is (a pointer to) a brand new point created with new.

Deprecated:
Please use GetInverseTransform and then call the forward transform function
Compute distance between two affine transformations

This method computes a ``distance'' between two affine transformations. This distance is guaranteed to be a metric, but not any particular metric. (At the moment, the algorithm is to collect all the elements of the matrix and offset into a vector, and compute the euclidean (L2) norm of that vector. Some metric which could be used to estimate the distance between two points transformed by the affine transformation would be more useful, but I don't have time right now to work out the mathematical details.)

This method computes the distance from self to the identity transformation, using the same metric as the one-argument form of the Metric() method.

Construct an AffineTransform object

This method constructs a new AffineTransform object and initializes the matrix and offset parts of the transformation to values specified by the caller. If the arguments are omitted, then the AffineTransform is initialized to an identity transformation in the appropriate number of dimensions.

Destroy an AffineTransform object

Print contents of an AffineTransform

Definition at line 74 of file itkAffineTransform.h.


Variable Documentation

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this* itk::application
 

Definition at line 56 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the and b* defines the translation of the origin from the source to the* target More A can also define anisotropic scaling and* shearing transformations Any good textbook on computer graphics* will discuss coordinate transformations in more detail Several of* the methods in this class are designed for this purpose and use the* language appropriate to coordinate conversions* * Any two affine transformations may be composed and the result is* another affine transformation the order is important* Given two affine transformations T1 and we will say that* precomposing T1 with T2 yields the transformation which applies* T1 to the and then applies T2 to that result to obtain the* target itk::Conversely
 

Definition at line 64 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target itk::coordinates
 

Definition at line 56 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the and b* defines the translation of the origin from the source to the* target More itk::generally
 

Definition at line 56 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the and b* defines the translation of the origin from the source to the* target More A can also define anisotropic scaling and* shearing transformations Any good textbook on computer graphics* will discuss coordinate transformations in more detail Several of* the methods in this class are designed for this purpose and use the* language appropriate to coordinate conversions* * Any two affine transformations may be composed and the result is* another affine transformation itk::However
 

Definition at line 64 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a itk::point
 

Definition at line 56 of file itkAffineTransform.h.

an object of type Vector transforms as *a vector **One common use of affine transformations is to define coordinate *conversions in two and three dimensional space In this x is a two or three dimensional vector containing the *source coordinates of a y is a vector containing the *target the matrix A defines the scaling and rotation *of the coordinate systems from the source to the and b *defines the translation of the origin from the source to the *target More A can also define anisotropic scaling and *shearing transformations Any good textbook on computer graphics *will discuss coordinate transformations in more detail Several of *the methods in this class are designed for this purpose and use the *language appropriate to coordinate conversions **Any two affine transformations may be composed and the result is *another affine transformation the order is important *Given two affine transformations T1 and we will say that *precomposing T1 with T2 yields the transformation which applies *T1 to the and then applies T2 to that result to obtain the *target we will say that postcomposing T1 with T2 *yields the transformation which applies T2 to the itk::source
 

Definition at line 64 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the and b* defines the translation of the origin from the source to the* target More A can also define anisotropic scaling and* shearing transformations Any good textbook on computer graphics* will discuss coordinate transformations in more detail Several of* the methods in this class are designed for this purpose and use the* language appropriate to coordinate conversions* * Any two affine transformations may be composed and the result is* another affine transformation the order is important* Given two affine transformations T1 and itk::T2
 

Definition at line 64 of file itkAffineTransform.h.

an object of type Vector transforms as* a vector* * One common use of affine transformations is to define coordinate* conversions in two and three dimensional space In this x is a two or three dimensional vector containing the* source coordinates of a y is a vector containing the* target the matrix A defines the scaling and rotation* of the coordinate systems from the source to the itk::target
 

Definition at line 56 of file itkAffineTransform.h.

* Affine transformation of a vector but other uses are possible as well* * An affine transformation is defined mathematically as a linear* transformation plus a constant offset If A is a constant n x n* matrix and b is a constant n itk::vector
 

Definition at line 43 of file itkAffineTransform.h.

* Affine transformation of a vector but other uses are possible as well* * An affine transformation is defined mathematically as a linear* transformation plus a constant offset If A is a constant n x n* matrix and b is a constant n then itk::y
 

Initial value:

 Ax+b defines an
 * affine transformation from the n-vector x to the n-vector y.
 *
 * The difference between two points is a vector and transforms
 * linearly

Definition at line 43 of file itkAffineTransform.h.


Generated at Sun Jul 9 18:46:13 2006 for ITK by doxygen 1.4.2 written by Dimitri van Heesch, © 1997-2000