Step 3: Find Matching Features Between Images: you can read the different tutorials on 2D Features framework
Step 4: Estimate Transformation: cv::getAffineTransform, as there is no RANSAC version of getAffineTransform, you could implement yourself the RANSAC framework and call getAffineTransform on a subset of points