PathTurnAngleLocalMaxima
Finds the local maxima of the profile of turn angles of a path.
Applications:Detection of feature points related to object corners.
Syntax
C++
C#
Python
def PathTurnAngleLocalMaxima( inPath: Path, /, *, inAllowedTurnDirection: TurnAngleDirection = TurnAngleDirection.All, inResultPrecision: TurnAnglePrecision = TurnAnglePrecision.PointPrecise, inMinTurnAngle: float = 30.0, inMinDistance: float = 0.0, inSmoothingStdDev: float = 0.6, diagSmoothedPath: Path | None = None, diagTurnAngleProfile: Profile | None = None ) -> ( outTurnAngleMaximaIndices: list[float], outTurnAngleMaximaPoints: list[Point2D], outTurnAngleMaximaAngles: list[float] )
Parameters
| Name | Type | Range | Default | Description | |
|---|---|---|---|---|---|
![]() |
inPath | Path | Input path | ||
![]() |
inAllowedTurnDirection | TurnAngleDirection | TurnAngleDirection.All | Allows to detect only left-turns, only right-turns or both | |
![]() |
inResultPrecision | TurnAnglePrecision | TurnAnglePrecision.PointPrecise | Switches between pixel-precise or subpixel-precise detection of the found maxima | |
![]() |
inMinTurnAngle | float | 0.0 - 180.0 | 30.0 | Minimal value of a relevant angle |
![]() |
inMinDistance | float | 0.0 - ![]() |
0.0 | Minimal distance on the path between two local maxima assuming each path segment has unit length |
![]() |
inSmoothingStdDev | float | 0.0 - ![]() |
0.6 | Standard deviation of the gaussian smoothing applied to the input path |
![]() |
outTurnAngleMaximaIndices | list[float] | Indices of found local maxima | ||
![]() |
outTurnAngleMaximaPoints | list[Point2D] | Found local maxima of turn angle profile of the smoothed input path | ||
![]() |
outTurnAngleMaximaAngles | list[float] | Turn angles of found local maxima | ||
![]() |
diagSmoothedPath | Path | None | None | Input path smoothed with gaussian kernel | |
![]() |
diagTurnAngleProfile | Profile | None | None | Profile of turn angles at characteristic points of the smoothed input path |




