Resource Base
Table of contents

Quadrilateral

The Quadrilateral class represents a quadrilateral shape in 2D space, which contains an array of four points, representing the vertices of the quadrilateral.

Definition

Namespace: com.dynamsoft.core.basic_structures

Assembly: DynamsoftCore.aar

class Quadrilateral

Methods & Attributes

Attributes Type Description
points android.graphics.Point[] Four vertexes in a clockwise direction of a quadrilateral. Index 0 represents the left-most vertex.
Method Description
contains Check whether the input point is contained by the quadrilateral.
getBoundingRect Get the bounding rectangle of the quadrilateral.
getArea Get the area of the quadrilateral.

points

Four vertexes in a clockwise direction of a quadrilateral. Index 0 represents the left-most vertex.

Point[] points;

contains

Check whether the input point is contained by the quadrilateral.

boolean contains(Point point);

Parameters

[in] point: Input a point.

Return Value

A boolean value that indicates whether the point is contained by the quadrilateral.

getBoundingRect

Get the bounding rectangle of the quadrilateral.

Rect getBoundingRect();

Return Value

The bounding rectangle of the quadrilateral.

getArea

Get the area of the quadrilateral.

int getArea();

Return Value

The area of the quadrilateral.

This page is compatible for:

Is this page helpful?

YesYes NoNo

In this article:

latest version

    Change +