|
int | AcceptScore [get, set] |
| The accept score used in detection. It defines the minimum score for identifying the edge as a good line. You may pick a proper score with help of line score chart. More...
|
|
int | EdgeWidth [get, set] |
| The edge width of the line used in detection, in 1 ~ 10. Edge width defines the count of pixels along the whole edge transition. Blurred edge indicates larger edge width value to find a stable result. Usually, it's fine to just use default setting (3).
|
|
LPVFindBy | FindBy [get, set] |
| The detection searching strategy. It defines how to select the result lines if there's more than expected line candidates.
|
|
int | MaxCount [get, set] |
| The maximum of lines to find.
|
|
BOOL | NormScore [get, set] |
| Whether we should normalize the score based on maximum gradient in region.
|
|
LPVPolarity | Polarity [get, set] |
| The detection edge polarity.
Polarity defines the edge transition according to region's direction, black pixels are dark, white pixels are light. More...
|
|
This interface provide functionalities of line detection.
Line detector is designed to locate a single or multiple line edges in given image and along the region's direction.
The algorithm is real-time and of sub-pixel accuracy, while the limitation is it could only detect parallel lines with small angle range (-10, +10) relative to the region's direction. So, to use this detector, you should have a basic idea of the target lines' direction.
To use this interface, you should create a LLineDetector object.
Example Code
C++
ILLineDetectorPtr lineDetector = LLineDetector::Create();
lineDetector->Polarity = LPVPolarity::LPVPolarityEitherEdge;
LPVErrorCode err = lineDetector->Detect(img, roi, &lineResults);
if (err != LPVErrorCode::LPVNoError) return;
LPVErrorCode
This enumeration represents the type of a LPV function error.
Definition: LPVCore.idl:530
C#
LLineDetector lineDetector = new LLineDetector();
lineDetector.Polarity =
LPVPolarity.LPVPolarityEitherEdge;
LPVErrorCode err = lineDetector.Detect(img, (LRotRectRegion)roi, out lineResults);
LPVPolarity
This enumeration represents the polarity of the edge or object to be located.
Definition: LPVCore.idl:1094
COM
ILLineDetectorPtr lineDetector = LLineDetector::Create();
lineDetector->Polarity = LPVPolarity::LPVPolarityEitherEdge;
LPVErrorCode err = lineDetector->Detect(img, roi, &lineResults);
if (err != LPVErrorCode::LPVNoError) return;