@ -519,6 +519,8 @@ Creates a smart pointer to a LineSegmentDetector object and initializes it.
.. ocv:function :: Ptr<LineSegmentDetector> createLineSegmentDetector(int _refine = LSD_REFINE_STD, double _scale = 0.8, double _sigma_scale = 0.6, double _quant = 2.0, double _ang_th = 22.5, double _log_eps = 0, double _density_th = 0.7, int _n_bins = 1024)
.. ocv:function :: Ptr<LineSegmentDetector> createLineSegmentDetector(int _refine = LSD_REFINE_STD, double _scale = 0.8, double _sigma_scale = 0.6, double _quant = 2.0, double _ang_th = 22.5, double _log_eps = 0, double _density_th = 0.7, int _n_bins = 1024)
.. ocv:pyfunction :: cv2.createLineSegmentDetector([, _refine[, _scale[, _sigma_scale[, _quant[, _ang_th[, _log_eps[, _density_th[, _n_bins]]]]]]]]) -> retval
:param _refine: The way found lines will be refined:
:param _refine: The way found lines will be refined:
* * *LSD_REFINE_NONE* * - No refinement applied.
* * *LSD_REFINE_NONE* * - No refinement applied.
@ -550,6 +552,8 @@ Finds lines in the input image. See the lsd_lines.cpp sample for possible usage.
.. ocv:function :: void LineSegmentDetector::detect(const InputArray _image, OutputArray _lines, OutputArray width = noArray(), OutputArray prec = noArray(), OutputArray nfa = noArray())
.. ocv:function :: void LineSegmentDetector::detect(const InputArray _image, OutputArray _lines, OutputArray width = noArray(), OutputArray prec = noArray(), OutputArray nfa = noArray())
.. ocv:pyfunction :: cv2.createLineSegmentDetector.detect(_image[, _lines[, width[, prec[, nfa]]]]) -> _lines, width, prec, nfa
:param _image A grayscale (CV_8UC1) input image.
:param _image A grayscale (CV_8UC1) input image.
If only a roi needs to be selected, use ::
If only a roi needs to be selected, use ::
lsd_ptr->detect(image(roi), lines, ...);
lsd_ptr->detect(image(roi), lines, ...);
@ -585,6 +589,8 @@ Draws the line segments on a given image.
.. ocv:function :: void LineSegmentDetector::drawSegments(InputOutputArray _image, InputArray lines)
.. ocv:function :: void LineSegmentDetector::drawSegments(InputOutputArray _image, InputArray lines)
.. ocv:pyfunction :: cv2.createLineSegmentDetector.drawSegments(_image, lines) -> _image
:param image: The image, where the liens will be drawn. Should be bigger or equal to the image, where the lines were found.
:param image: The image, where the liens will be drawn. Should be bigger or equal to the image, where the lines were found.
:param lines: A vector of the lines that needed to be drawn.
:param lines: A vector of the lines that needed to be drawn.
@ -596,13 +602,15 @@ Draws two groups of lines in blue and red, counting the non overlapping (mismatc
.. ocv:function :: int LineSegmentDetector::compareSegments(const Size& size, InputArray lines1, InputArray lines2, InputOutputArray _image = noArray())
.. ocv:function :: int LineSegmentDetector::compareSegments(const Size& size, InputArray lines1, InputArray lines2, InputOutputArray _image = noArray())
.. ocv:pyfunction :: cv2.createLineSegmentDetector.compareSegments(size, lines1, lines2[, _image]) -> retval, _image
:param size: The size of the image, where lines1 and lines2 were found.
:param size: The size of the image, where lines1 and lines2 were found.
:param lines1: The first group of lines that needs to be drawn. It is visualized in blue color.
:param lines1: The first group of lines that needs to be drawn. It is visualized in blue color.
:param lines2: The second group of lines. They visualized in red color.
:param lines2: The second group of lines. They visualized in red color.
:param image: Optional image, where the lines will be drawn. The image should be color in order for lines1 and lines2 to be drawn in the above mentioned colors.
:param image: Optional image, where the lines will be drawn. The image should be color(3-channel) in order for lines1 and lines2 to be drawn in the above mentioned colors.