a displacement that varies polynomially across the frame
Degree 1 is an affine and could equally be a spatialTransformShift - inv converts to one, since a matrix has an exact inverse where a polynomial does not. Degree 2 is what mops up the residual curvature a projective stage leaves behind.
The coefficients describe the DISPLACEMENT, not the mapped position, so the identity is c = 0.
Syntax
T = spatialTransformPoly(c,degree)
T = spatialTransformPoly.fit(posA,posB,'degree',2)
T = spatialTransformPoly.fit(posA,posB,'degree',2,'weights',w)Input
| c | m × 2 coefficients, one column per displacement component |
| degree | 1 or 2 |
| posA, posB | vector3d, the same points in the two frames |
| w | double, one weight per point |
Output
| T | spatialTransformPoly |
Class Properties
| c | m x 2 coefficients against [1 x y] or [1 x y x^2 xy y^2] |
| degree | 1 or 2 |