Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Lines detection

Hi All, the following is a quite difficult task so any kind of help, even simple, will be much appreciated.

After color segmentation I generated the following image

image description

I need to get lines that approximates white areas (roads), as shown in the following hand-made image

image description

Using probabilistic HoughLines with following parameters (image and lines are Mat instances):

Imgproc.HoughLinesP(image, lines, 2, Math.PI /180, 200, 100, 5);

I get the following result:

image description

I tried several combinations of parameters and shown result seems to be the best that I can achieve.

My questions:

  1. Overall, what do you think of this approach ?

  2. Any idea on how to select 'strongest' lines after HoughLines transform ? Is there any way to cluster every bundle of lines into a single significative line ?