spo
di
gpoi
tsa
dcreatesatra
sformatio
structureusemaketformorcp2tformTherelativecodeisshow
belowa
dtheparameteri
put_poi
tsa
dbase_poi
tsaredefi
edi
thelaststepbycomma
dcpselect
TFORMcp2tformi
put_poi
tsbase_poi
tsprojective
5Exte
dthemfileof4applythetra
sformtotheseco
dimagebyusi
gthetra
sformatio
structurei
imtra
sformHi
tusetheoptio
sXDataYDataa
dXYscaletoassurethattheoutputimageislargee
oughtoco
tai
bothimagesreadthehelpofimtra
sformI
ordertofi
dtherightpositio
youmaywa
ttocalculatewherethecor
ersoftheseco
dimageshouldbelocatedi
thetra
sformedimageYouca
calculatethatusi
gtformfwd
3
fImageProcessi
gComputerVisio
Thecodeisshow
asbelowthefigureoftra
sformedimage2isshow
withxa
dyaxisi
Figure3a
dthefigureofimage1withaxisdisplaysasarefere
ce
img2_trxdataydataimtra
sformimg2TFORMfigureimshowimg2_trXDataxdataYDataydataaxiso
figureimshowimg1axiso
Figure31Figure32I
ordertogetthesufficie
tsizeofthefi
alimagea
dfi
dthecorrectlocatio
oftheimage1a
dtra
sformedimage2i
itthefollowi
gparametersareobtai
ed
ijasizeimg1m
bsizeimg2_trxrou
dxdata1yrou
dydata1
Becausexdata10a
dydata10therelativelocatio
ofimg1a
dimg2_trhas4situatio
swhichisshow
i
Figure4144Actuallytherealsituatio
fortheassig
me
tisthecasei
Figure41Asi
dicatedi
thefigureitisobviousthatthecolum
sizeofthefi
alimageshouldbeyiorma
dtherowsizeshouldbex
orjThecodewhichisforobtai
i
gthesizeisshow
belowI
theAppe
dixa
dmymfilethecodefortheco
ditio
ydata10isalsoaddedformorege
eraluse
colum
_sizemaxmyirow_sizemaxx
j
4
fImageProcessi
gComputerVisio
Figure41
Figure42
Figure43
Figure44
Alsoaccordi
gtotheFigure41Figure44i
spiteofwhichcaseitisthecorrectlocatio
ofim1i
theexte
dedimageshouldbefromYy1toYyIa
dX1toXjthecorrectlocatio
ofim2_tri
theexte
dedimageshouldbefromY1toYma
dXx1toXx
Followi
gisthecodebuildi
gthe
ewmatrixoftheexte
dedsizea
dlocati
gthetwoimagesi
eachexte
dedimage
img_outui
t8zeroscolum
_sizerow_size3img1_largeui
t8zeroscolum
_sizerow_size3img2_largeui
t8zeroscolum
_sizerow_size3img1_largey1yi1j13img1img2_large1mx1x
13img2_tr
Theresultforimage1a
dimage2areshow
i
Figure51a
dFigure52respectively5
fImageProcessi
gComputerVisio
Figure51
Figure526
fImageProcessi
gComputerVisio
6Copythefirstimagetothetra
sformedimageobtai
edi
5Notecopyittotherightpositio
asi
dicatedbyyourchoiceofXDataYDataa
dXYscr