How write this image with plotted boundary in a folder
1 view (last 30 days)
Show older comments
figure;imshow(Img);
title('Hill Climbing Segmentation');
axis image; % Make sure image is not artificially stretched because of screen's aspect ratio.
hold on;
boundaries = bwboundaries(bw);
numberOfBoundaries = size(boundaries, 1);
for k = 1 : numberOfBoundaries
thisBoundary = boundaries{k};
plot(thisBoundary(:,2), thisBoundary(:,1), 'g', 'LineWidth', 2);
end
hold off;
have got this image want to write this image in directory with its boundary how to write,have used imwrite() in for loop but it write only image not image with boundary is not present
0 Comments
Answers (1)
Image Analyst
on 1 Jul 2015
You can use getimage() though it will just get a 24 bit RGB image of what's in the axes, so the graphics won't be burned in at the full image resolution. Though maybe that will be good enough for your needs. Then just call imwrite to write the image to disk:
displayedImage = getimage();
imwrite(displayedImage, fullFileName);
0 Comments
See Also
Categories
Find more on Image Processing Toolbox in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!