How to plot entire boundary points ?
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Selva Karna
el 22 de Ag. de 2017
Comentada: Selva Karna
el 29 de Ag. de 2017
How to plot entire boundary points ? I have 7 cell boundaries i need to plot entire boundaries how is it possible?
3 comentarios
José-Luis
el 22 de Ag. de 2017
Most such things are possible.
How?
Difficult to say without knowing your data and what you expect the output to be.
Respuesta aceptada
Image Analyst
el 25 de Ag. de 2017
You have multiple blobs so multiple boundaries, each of a different length so that's why they're in a cell array. You need to extract each boundary one at a time and plot it. See this snippet. Adapt as needed.
imshow(originalImage);
title('Outlines, from bwboundaries()', 'FontSize', captionFontSize);
axis image; % Make sure image is not artificially stretched because of screen's aspect ratio.
hold on;
boundaries = bwboundaries(binaryImage);
numberOfBoundaries = size(boundaries, 1);
for k = 1 : numberOfBoundaries
thisBoundary = boundaries{k};
plot(thisBoundary(:,2), thisBoundary(:,1), 'g', 'LineWidth', 2);
end
hold off;
2 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Image Processing Toolbox en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!