Can anybody suggest me to region fill this image on the basis of neighbouring pixels?

3 views (last 30 days)
It is a color image where I have to fill the black/red regions depending on the color of neighbouring pixels.If the number of green pixels in the neighbour is more,then it will be filled with green,and if its red,then it is to be filled with red.Please help.

Answers (0)

Categories

Find more on Read, Write, and Modify Image 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!