I'm trying to find all the neighbors of a given cell in a voronoi diagram. For example, given the following diagram, if I want to find the neighbors of the cell 1, then I should be able to return the points 2, 3 and 4.
Any hints on how to do so ?
I didn't explained myself very well, I only have the image (pixels with position and colors), not the graph itself. My struggle is that I just can't see an efficient way to create the graph form the image. In the image below you can see the problem better because I need an algorithm that recognizes black dots and from there search for all the neighbors.