Image Processing Toolbox User's Guide |
Step 6: Using XData and YData Output Values
Another approach is to compute the full extent of the registered image and use the optional imtransform
syntax that returns the x- and y-coordinates that indicate the transformed image's position relative to the base image's pixel coordinates.
Display the registered image. Overlay a semi-transparent version of the base image for comparison. Adjust the axes to include the full base image. In this case, notice how the registration is evident and the full extent of both images is visible as well.
figure; imshow(registered2, 'XData', xdata, 'YData', ydata) hold on h = imshow(base, gray(256)); set(h, 'AlphaData', 0.6) ylim = get(gca, 'YLim'); set(gca, 'YLim', [0.5 ylim(2)])
Step 5: Using XData and YData Input Parameters | Image Registration |
© 1994-2005 The MathWorks, Inc.