Woolz Image Processing  Version 1.7.5
WlzAffineTransformLSq
Name
WlzAffineTransformLSq - Computes an affine transform from a list of verticies and vertex displacements.
Synopsis
WlzAffineTransformLSq [-o <output object file>]
    [-a] [-r] [-t] [-h] [<input data file>]
Options
-a Compute 2D affine transform.
-o Output object file name.
-r Compute 2D registration transform, affine but no scale or shear.
-t Compute 2D translation transform.
-h Help - print help message
-v Verbose operation
Description
WlzAffineTransformLSq computes an affine transform from the given list of verticies and thier displacements. The input data must have records with the format:
<vertex x> <vertex y> <displacement x> <displacement y>
Examples
cat tst.num
  1.0  1.0  2.1  1.0
  2.0  1.0  1.0  0.1
  2.0  2.0  2.1 -1.0

WlzAffineTransformLSq tst.num | WlzFacts
  Object type: WLZ_AFFINE_TRANS.
  Linkcount: 0.
  Transform type: WLZ_TRANSFORM_2D_AFFINE.
  Linkcount: 1.
  tx: 2.1.
  ty: 3.
  tz: 0.
  scale: 1.
  theta: -1.5708.
  phi: 0.
  alpha: 0.2.
  psi: 0.785398.
  xsi: 0.
  invert: 0.

WlzAffineTransformLSq -r tst.num | WlzFacts
  Object type: WLZ_AFFINE_TRANS.
  Linkcount: 0.
  Transform type: WLZ_TRANSFORM_2D_AFFINE.
  Linkcount: 1.
  tx: 2.15156.
  ty: 3.09784.
  tz: 0.
  scale: 1.
  theta: -1.62075.
  phi: 0.
  alpha: 0.
  psi: 0.
  xsi: 0.
  invert: 0.

WlzAffineTransformLSq -t tst.num | WlzFacts
  Object type: WLZ_AFFINE_TRANS.
  Linkcount: 0.
  Transform type: WLZ_TRANSFORM_2D_AFFINE.
  Linkcount: 1.
  tx: 1.73333.
  ty: 0.0333333.
  tz: 0.
  scale: 1.
  theta: 0.
  phi: 0.
  alpha: 0.
  psi: 0.
  xsi: 0.
  invert: 0.
File
WlzAffineTransformLSq.c
See Also
WlzFacts(1) WlzAffineTransformObj(1) WlzAffineTransformLSq(3) WlzAffineTransformObj(3)