added a depth first search style algo to find connected components that ought to represent the straight lines