Identify neighbours in image after finding regionprops centroids
Afficher commentaires plus anciens
I have an example image with different RGB color values. I have used ColorThresholder to create a mask to get every different RGB color and then used regionprops (extrema and centroid) to get the corner points and centroids of each shape. I would now like to calculate the distance between neighbouring centroids and corner points. In other words, I would like to store the data in such a way that it is clear that the yellow and green squares are connected to the black one and that I can thereby easily calculate the distance between those centroids. What is the best way to store the data after using regionprops to be able to achieve this?
Any help or suggestion will be appreciated.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Polygonal Shapes dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!