An Affine transformation preserves parallel lines but not angles, and it is usually adopted as an approximation for projective transform when parallel lines almost preserve their parallelism. The model is based on 6 parameters and, since points at infinity stay at infinity while finite points remain finite points, we can assume that its transform is:
Where x, the 3 elements vector on the right, is expressed in 2D uniform coordinates with the last value equal to 1. While the output x' is in inhomogeneous coordinates. 3 corresponding 2D points between two images are sufficient to define the 6 parameters of the transformation and it can be considered a generalization of the scaling transform where the parameters are only 4 (1 for scaling, 2 for translation and one for rotation). The scaling transform:
An exemple for the affine transform is the following: