irtkBSplineFreeFormTransformation4D Class Reference

#include <irtkBSplineFreeFormTransformation4D.h>

Inheritance diagram for irtkBSplineFreeFormTransformation4D:

Inheritance graph
[legend]
Collaboration diagram for irtkBSplineFreeFormTransformation4D:

Collaboration graph
[legend]

List of all members.


Detailed Description

Class for free form transformations based on tensor product B-splines.

This class implements 4D free form transformation using B-splines.

For more details about the implementation see Lee, Wolberg and Shin, IEEE Transactions on Visualization and Computer Graphics, Vol. 3, No. 3, 1997.

Definition at line 28 of file irtkBSplineFreeFormTransformation4D.h.


Public Member Functions

 irtkBSplineFreeFormTransformation4D ()
 Constructor.
 irtkBSplineFreeFormTransformation4D (irtkBaseImage &, double=1, double=1, double=1, double=1)
 Constructor.
 irtkBSplineFreeFormTransformation4D (double x1, double y1, double z1, double t1, double x2, double y2, double z2, double t2, double dx, double dy, double dz, double dt, double *xaxis, double *yaxis, double *zaxis)
 Constructor.
 irtkBSplineFreeFormTransformation4D (const class irtkBSplineFreeFormTransformation4D &)
 Copy Constructor.
virtual ~irtkBSplineFreeFormTransformation4D ()
 Destructor.
virtual double Approximate (double *, double *, double *, double *, double *, double *, double *, int)
 Approximate displacements: This function takes a set of points and a set of displacements and find a FFD which approximates these displacements.
virtual void Interpolate (double *dxs, double *dys, double *dzs)
 Interpolates displacements: This function takes a set of displacements defined at the control points and finds a FFD which interpolates these displacements.
virtual void Subdivide ()
 Subdivide FFD.
virtual void FFD1 (double &, double &, double &, double) const
 Calculates the FFD (for a point in FFD coordinates) with checks.
virtual void FFD2 (double &, double &, double &, double) const
 Calculates the FFD (for a point in FFD coordinates) without checks.
virtual void Transform (double &, double &, double &, double=0)
 Transforms a point.
virtual void Transform2 (double &, double &, double &, double=0)
 Transforms a point.
virtual void GlobalTransform (double &, double &, double &, double=0)
 Transforms a point using the global transformation component only.
virtual void LocalTransform (double &, double &, double &, double=0)
 Transforms a point using the local transformation component only.
virtual void GlobalDisplacement (double &, double &, double &, double=0)
 Calculates displacement using the global transformation component only.
virtual void LocalDisplacement (double &, double &, double &, double=0)
 Calculates displacement using the local transformation component only.
virtual void Jacobian (irtkMatrix &, double, double, double, double=0)
 Calculate the Jacobian of the transformation.
virtual void LocalJacobian (irtkMatrix &, double, double, double, double=0)
 Calculate the Jacobian of the local transformation.
virtual void GlobalJacobian (irtkMatrix &, double, double, double, double=0)
 Calculate the Jacobian of the global transformation.
virtual double Bending (double, double, double, double)
 Calculate the bending energy of the transformation.
virtual void BoundingBox (int, irtkPoint &, irtkPoint &, double=1) const
 Returns the bounding box for a control point (in mm).
virtual void BoundingBox (int, double &, double &, double &, double &, double &, double &, double &, double &, double=1) const
 Returns the bounding box for a control point.
virtual void BoundingBox (irtkGreyImage *, int, int &, int &, int &, int &, int &, int &, int &, int &, double=1) const
 Returns the bounding box for a control point (in pixels).
virtual void Print ()
 Prints the parameters of the transformation.
virtual const char * NameOfClass ()
 Returns a string with the name of the instantiated class.
virtual irtkCifstreamRead (irtkCifstream &)
 Reads a transformation from a file.
virtual irtkCofstreamWrite (irtkCofstream &)
 Writes a transformation to a file.

Static Public Member Functions

static double B (int, double)
 Returns the value of the i-th B-spline basis function.
static double B_I (int, double)
 Returns the 1st derivative value of the i-th B-spline basis function.
static double B_II (int, double)
 Returns the 2nd derivative value of the i-th B-spline basis function.
static int CheckHeader (char *)
 Check file header.

Protected Member Functions

virtual void Subdivide2D ()
 Subdivide FFD in 2D.
virtual void Subdivide3D ()
 Subdivide FFD in 3D.

Static Protected Member Functions

static double B0 (double)
 Returns the value of the first B-spline basis function.
static double B1 (double)
 Returns the value of the second B-spline basis function.
static double B2 (double)
 Returns the value of the third B-spline basis function.
static double B3 (double)
 Returns the value of the fourth B-spline basis function.
static double B0_I (double)
 Returns the 1st derivative value of the first B-spline basis function.
static double B1_I (double)
 Returns the 1st derivative value of the second B-spline basis function.
static double B2_I (double)
 Returns the 1st derivative value of the third B-spline basis function.
static double B3_I (double)
 Returns the 1st derivative value of the fourth B-spline basis function.
static double B0_II (double)
 Returns the 2nd derivative value of the first B-spline basis function.
static double B1_II (double)
 Returns the 2nd derivative value of the second B-spline basis function.
static double B2_II (double)
 Returns the 2nd derivative value of the third B-spline basis function.
static double B3_II (double)
 Returns the 2nd derivative value of the fourth B-spline basis function.

Static Protected Attributes

static double LookupTable [FFDLOOKUPTABLESIZE][4]
 Memory for lookup table for B-spline basis function values.
static double LookupTable_I [FFDLOOKUPTABLESIZE][4]
static double LookupTable_II [FFDLOOKUPTABLESIZE][4]

Member Function Documentation

virtual double irtkBSplineFreeFormTransformation4D::Approximate ( double *  ,
double *  ,
double *  ,
double *  ,
double *  ,
double *  ,
double *  ,
int   
) [virtual]

Approximate displacements: This function takes a set of points and a set of displacements and find a FFD which approximates these displacements.

After approximatation the displacements replaced by the residual displacement errors at the points

virtual void irtkBSplineFreeFormTransformation4D::Interpolate ( double *  dxs,
double *  dys,
double *  dzs 
) [virtual]

Interpolates displacements: This function takes a set of displacements defined at the control points and finds a FFD which interpolates these displacements.

Parameters:
dxs The x-displacements at each control point.
dys The y-displacements at each control point.
dzs The z-displacements at each control point.

virtual void irtkBSplineFreeFormTransformation4D::BoundingBox ( int  ,
irtkPoint ,
irtkPoint ,
double  = 1 
) const [virtual]

Returns the bounding box for a control point (in mm).

The last parameter specifies what fraction of the bounding box to return. The default is 1 which equals 100% of the bounding box.

virtual void irtkBSplineFreeFormTransformation4D::BoundingBox ( int  ,
double &  ,
double &  ,
double &  ,
double &  ,
double &  ,
double &  ,
double &  ,
double &  ,
double  = 1 
) const [virtual]

Returns the bounding box for a control point.

The last parameter specifies what fraction of the bounding box to return. The default is 1 which equals 100% of the bounding box.

Implements irtkFreeFormTransformation4D.

virtual void irtkBSplineFreeFormTransformation4D::BoundingBox ( irtkGreyImage *  ,
int  ,
int &  ,
int &  ,
int &  ,
int &  ,
int &  ,
int &  ,
int &  ,
int &  ,
double  = 1 
) const [virtual]

Returns the bounding box for a control point (in pixels).

The last parameter specifies what fraction of the bounding box to return. The default is 1 which equals 100% of the bounding box.

Implements irtkFreeFormTransformation4D.


The documentation for this class was generated from the following file: