フィルターのクリア

interpolation matlab roipoly 2D

1 回表示 (過去 30 日間)
Devraj Mandal
Devraj Mandal 2013 年 7 月 11 日
回答済み: praveen chandaliya 2017 年 8 月 12 日
I have two matrices X and Y. They are the set of coordinates in my 2D xy plane. I want to interpolate between this points. What I really require is to calculate all the coordinates through which my interpolated curve will pass.
X=[1;4;4;2];
Y=[1,1,6,4];
X = [X(:);X(1)];
Y = [Y(:);X(1)];
If I do interpolation it should give me a quadrilateral figure. I want to get the coordinates through which my interpolated figure passes.
Till now I am using the roipoly function of MATLAB as follows.
I = imread('cameraman.tif');
Img=I;
I=double(I(:,:,1));
BW = roipoly(I,X,Y);
Now I can get the coordinates through which the figure passes.
Obviously some kind of interpolation is being done by roipoly. Is it different from normal cubic spline interpolation ? Will I get a better result if I use spline interpolation? How can I use it. It is imperative that I have to calculate the points through which the curve passes.

回答 (1 件)

praveen chandaliya
praveen chandaliya 2017 年 8 月 12 日
roiploy function return type give coordinate [x, y, binaryImage, xi, yi] = roipoly(I);

カテゴリ

Help Center および File ExchangeInterpolation についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by