91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 1.06MB
    文件類型: .zip
    金幣: 2
    下載: 0 次
    發(fā)布日期: 2023-08-16
  • 語言: Matlab
  • 標(biāo)簽:

資源簡介

通過移動(dòng)的最小二乘法改變和自定義的控制點(diǎn)操作圖片。Image Deformation Using Moving Least Squares 移動(dòng)最小二乘法 圖像變形(matlab實(shí)現(xiàn))

資源截圖

代碼片段和文件信息

function?P?=?getpoints(Nforcemark)
%?GETPOINTS??Allow?to?get?from?the?current?figure?a?set?of?N?points
%
%??This?function?allow?to?select?a?set?of?N?points?by?picing?them?with?the
%?mouse?on?the?current?figure.?If?the?parameter?is?omitted?the?number?of
%?points?is?selected?from?the?user.
%
%??Params:
%
%?N?????????=?The?number?of?points.?(def=any=0)
%?force?????=?Points?must?be?precisely?N?(true)??(def=true)
%?mark??????=?The?marker?to?be?used?‘‘?for?no?marker.?(def=‘ro‘)
%
%?P?????????=?The?points?(as?a?matrix?2xN)
%
%??Examples:
%
%??Plot?the?selected?points:
%?>>?imshow(img);?hold?on;?plotpoints(getpoints);

%?The?def?params:
if?nargin<1?N?=?0;?end
if?nargin<2?force?=?true;?end
if?nargin<3?mark?=?‘ro‘;?end

%?Obtaining?the?points:
npts?=?0;
P?=?[];
if?N==0
????????[XY]?=?getpts;
????????P?=?[XY]‘;
????????npts?=?numel(X);
else
????while?(force?&&?npts????????%?Get?another?set?of?points:
????????if?strcmp(‘‘mark)
????????????[XY]?=?ginput(N-npts);
????????else
????????????[XY]?=?GetPoints(N-nptsmark);
????????end

????????%?Converting?the?points?format?and?counting:
????????P?=?[P[XY]‘];
????????npts?=?size(P2);
????end
end

%?If?required?removing?the?exceding?points:
if?nargin>0?&&?size(P2)>N
????P?=?P(:1:N);
end

%?------------------------?LOCAL?FUNCTIONS?------------------------

%?Get?a?set?of?points?marking?the?points:
function?[XY]?=?GetPoints(Nmark)

%?Prepare?holding
washold?=?ishold;
if?~washold
hold?on;
end

%?The?acquisition?cicle:
X?=?zeros(N1);
Y?=?zeros(N1);
for?ind=1:N
????%?Get?a?point:
????[X(ind)Y(ind)]?=?ginput(1);
????%?Mark?the?point:
????plot(X(1:ind)Y(1:ind)mark);
end

%?Correct?the?old?hold?state
if?~washold?hold?off;?end

?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2019-04-02?20:44??MLS\
?????文件????????6843??2006-09-10?02:42??MLS\MLSD2DTransform.m
?????文件????????1960??2006-09-08?17:59??MLS\MLSD2DWarp.m
?????文件???????10238??2006-09-10?02:41??MLS\MLSD2DlinesPrecompute.m
?????文件????????5577??2006-09-10?02:41??MLS\MLSD2DpointsPrecompute.m
?????文件????????6337??2006-09-13?20:56??MLS\MLSDdemo.m
?????文件????????3009??2006-09-11?21:23??MLS\MLSDeformImage.m
?????文件????????2789??2006-09-11?21:23??MLS\MLSDeformPoints.m
?????文件????????1788??2005-07-20?22:42??MLS\getpoints.m
?????目錄???????????0??2019-04-02?20:44??MLS\html\
?????文件???????17744??2006-09-13?20:59??MLS\html\MLSDdemo.html
?????文件????????9448??2006-09-13?20:59??MLS\html\MLSDdemo.png
?????文件??????534278??2006-09-13?20:58??MLS\html\MLSDdemo_03.png
?????文件??????548173??2006-09-13?20:59??MLS\html\MLSDdemo_04.png
?????文件????????1273??2005-04-26?21:39??MLS\plotpoints.m
?????文件????????1876??2006-04-25?00:18??MLS\plotpointsLabels.m
?????文件????????1207??2005-05-04?21:18??MLS\plotshape.m
?????文件?????????942??2005-12-15?20:20??MLS\points2dnormalize.m
?????文件????????1254??2005-06-06?05:07??MLS\strin.m

評(píng)論

共有 條評(píng)論