dungen
dungen copied to clipboard
Region Detection: Detect minimum regions
What it does
If region is smaller than X size, collapse region and add to neighbor with biggest border. Check if neighbor is smaller than min region before collapse and recurse?
Implementation
The island detection code should be able to handle this, just modify to detect regions instead, find neighbor region, merge border into bigger region and merge this into region.