Package io.scanbot.sdk.util.view
Class PolygonViewHelper.Line
-
- All Implemented Interfaces:
public class PolygonViewHelper.Line
Representation of line
Calculates line by two points and finds intersection points with other lines General line formula is a * x + b * y + c = 0
-
-
Constructor Summary
Constructors Constructor Description PolygonViewHelper.Line()
-
Method Summary
Modifier and Type Method Description PointF
getIntersectionPoint(PolygonViewHelper.Line line)
void
calculateLine(PointF start, PointF end)
Calculate all 3 components of the line double
getDistanceToPoint(PointF point)
Calculates distance to point Should be used after line components are calculated -
-
Method Detail
-
getIntersectionPoint
PointF getIntersectionPoint(PolygonViewHelper.Line line)
-
calculateLine
void calculateLine(PointF start, PointF end)
Calculate all 3 components of the line
- Parameters:
start
- starting point of segment laying on this lineend
- ending point of segment laying on this line
-
getDistanceToPoint
double getDistanceToPoint(PointF point)
Calculates distance to point Should be used after line components are calculated
-
-
-
-