Borrar filtros
Borrar filtros

Why bwboundaries with roipoly change the size of a rectangle?

1 visualización (últimos 30 días)
Meshooo
Meshooo el 24 de Mzo. de 2014
Editada: Meshooo el 25 de Mzo. de 2014
Dear all,
Could anyone tell me why the size of rectangle is changed?
x = [4 10 10 4 4];
y = [4 4 10 10 4];
BW = poly2mask(x,y,20,20); %binary image that contains a small rectangle
B = bwboundaries(BW);
b = B{1};
X = b(:, 1);
Y = b(:, 2);
hpoly = roipoly(BW,Y,X);
figure, imshow(BW)
figure, imshow(hpoly)
Any idea will be appreciated.
Best, Meshoo

Respuestas (0)

Categorías

Más información sobre Image Processing Toolbox en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by