Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
pmi432 / LR07 / 2read / image processing toolbox guide.pdf
Скачиваний:
150
Добавлен:
18.03.2015
Размер:
18.08 Mб
Скачать

6 Spatial Transformations

Registered Image Truncated with Base Image Overlay

Step 7: 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 in the intrinsic coordinate system of the base image.

[registered2 xdata ydata] = imtransform(unregistered, tform,...

'FillValues', 255);

Display the registered image. Overlay a semi-transparent version of the base image for comparison.

figure; imshow(registered2, 'XData', xdata, 'YData', ydata) hold on

h = imshow(base, gray(256)); set(h, 'AlphaData', 0.6)

6-26

Register Image Using XData and YData Parameters

Registered Image with Base Image Overlay

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.

ylim = get(gca, 'YLim'); set(gca, 'YLim', [0.5 ylim(2)])

6-27

6 Spatial Transformations

Registered Image with Base Image Overlay and Adjusted Axes

6-28

Соседние файлы в папке 2read