I\'m wondering if there\'s a library implementation of this.
In OpenCV we have the concept of finding connected components with either 4-way or 8-way connectivity. I\'d l