-
Notifications
You must be signed in to change notification settings - Fork 3
Warping Images
First of all, to develop this practice, we used the warping slides following the different steps. Warping on a three-dimensional image uses a matrix to warp on the points that you exactly want to correct or deform of an image.
Choosing at least four points of the image will let us to create the matrix A (number_of_points x 9). Then we should compute the singular value decomposition of A = USVt. Then select the vector ‘vk’ that corresponds to the smallest singular vector of the V matrix and construct a new matrix H. Compute H up to minus 1. We must create a J(r,c), an image initialized with zeros as a matrix with the same dimensions of the first image I(r,c). For each (rJ ,cJ ) in J, we select (rI ,cI ) from I using the some equations. Since (rI , cI ) is fractional, we interpolate on the neighborhood of (rI , cI ) in I to compute J(rJ, cJ).
To use the application, you will have to load an image that will be the one warped. After that, choosing four points of the image will let you create the matrix A and correct the image as you want. The new image will be displayed after the whole process of transformation.
First image correspond to the initial one and the second after the warping on the chosen points
Video of how it works: https://youtu.be/FLO3iQfIBFo