Table of contents

LineSegment

The LineSegment class represents a line segment in 2D space, which contains the start point and end point of the line segment.

Definition

Namespace: com.dynamsoft.core.basic_structures

Assembly: DynamsoftCaptureVisionBundle.aar

class LineSegment

Attributes & Methods

Attributes Type Description
startPoint android.graphics.Point The starting point of the line segment.
endPoint android.graphics.Point The ending point of the line segment.
id int The ID of the line segment.
Method Description
LineSegment The constructor.
LineSegment(startPoint,endPoint) Constructs a line segment from the start point and end point.
LineSegment(startPoint,endPoint,id) Constructs a line segment from the start point, end point, and ID.
transformByMatrix Transforms the coordinates of the line segment by a transformation matrix.

startPoint

The start point of the line segment.

Point startPoint;

endPoint

The end point of the line segment.

Point endPoint;

id

The ID of the line segment.

int id;

LineSegment

The constructor.

LineSegment();

LineSegment(startPoint,endPoint)

Constructs a line segment from the start point and end point.

LineSegment(Point startPoint,Point endPoint);

LineSegment(startPoint,endPoint,id)

Constructs a line segment from the start point, end point, and ID.

LineSegment(Point startPoint,Point endPoint,int id);

transformByMatrix

Transforms the coordinates of the line segment by a transformation matrix.

LineSegment transformByMatrix(Matrix matrix);

This page is compatible for:

Is this page helpful?

YesYes NoNo

In this article: