How can I get back the original image of the segmented area after using active contour? the background is still black but the segmented area fills with the original colour image.
1 view (last 30 days)
Show older comments
clc clear all; close all; I = imread('B1_51.tif'); I=rgb2gray(I); imshow(I)
str = 'Click to select initial contour location. Double-click to confirm and proceed.';
title(str,'Color','b','FontSize',12);
disp(sprintf('\nNote: Click close to object boundaries for more accurate result.'));
mask = roipoly;
figure, imshow(mask)
title('Initial MASK');
maxIterations = 200;
bw = activecontour(I, mask, maxIterations, 'Chan-Vese');
figure, imshow(bw)
title('Segmented Image')
please give me some idea and comment about this! thank you.
0 Comments
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!