Clear Filters
Clear Filters

How to convert image to one pixel?

3 views (last 30 days)
jenifer Ask
jenifer Ask on 30 Dec 2019
How can I get from picture (main) to picture(convert) ?
I tried the following code but not the correct output.
originalImage=imread('main.png'); %
figure; imshow(originalImage)
binaryImage=im2bw(originalImage);
figure; imshow(binaryImage)
binaryImage_p = bwareaopen(binaryImage, 500);
figure; imshow(binaryImage_p)
skeletonImage = bwmorph(binaryImage, 'skel', inf);
figure; imshow(skeletonImage)

Answers (0)

Categories

Find more on Graphics Object Programming in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!