Resource Base
Table of contents

Class QuadDrawingItem

The QuadDrawingItem class extends the functionality of the DrawingItem class and is specifically tailored to handle quadrilateral-related drawing operations.

Name Description
constructor QuadDrawingItem() Constructor for the class.
getQuad() Retrieves the current quadrilateral being used for drawing.
setQuad() Sets the quadrilateral to be used for drawing.

QuadDrawingItem

Constructor for the class.

constructor(
    quad: Quadrilateral,
    drawingStyleId?: number
)

Parameters

quad: the quadrilateral to be drawn, of type Quadrilateral.

drawingStyleId: [Optional] the unique ID of the DrawingStyle to apply to this DrawingItem.

Code Snippet

let cameraView = cameraEnhancer.getCameraView();
let drawingLayer = cameraView.createDrawingLayer();
let quadItem = new Dynamsoft.DCE.QuadDrawingItem(
    {
        points:[{
            x: 50, 
            y: 50
        },{
            x: 500, 
            y: 50
        },
        {
            x: 500, 
            y: 500
        },{
            x: 50, 
            y: 500
        }]
    }
);
drawingLayer.addDrawingItem(quadItem);

See also

Quadrilateral

getQuad

Retrieves the current quadrilateral being used for drawing.

getQuad(): Quadrilateral;

Parameters

None.

Return Value

The current quadrilateral being used for drawing, of type Quadrilateral.

Code Snippet

quadItem.getQuad();

setQuad

Sets the quadrilateral to be used for drawing. This method allows changing the quadrilateral after the object has been instantiated.

setQuad(quad: Quadrilateral): void;

Parameters

quad: the quadrilateral to be drawn, of type Quadrilateral.

Return Value

None.

Code Snippet

quadItem.setQuad(/*A-New-Quadrilateral*/);

See also

Quadrilateral

This page is compatible for:

Version 1.0

Is this page helpful?

YesYes NoNo

In this article:

latest version

  • Latest version(4.0.2)
  • Version 4.x
    • Version 4.0.1
    • Version 4.0.0
  • Version 3.x
    • Version 3.3.10
    • Version 3.3.9
    • Version 3.3.8
    • Version 3.3.7
    • Version 3.3.6
    • Version 3.3.5
    • Version 3.3.4
    • Version 3.3.3
    • Version 3.3.2
    • Version 3.3.1
    • Version 3.3.0
    • Version 3.2.0
    • Version 3.1.0
    • Version 3.0.1
    • Version 3.0.0
  • Version 2.x
    • Version 2.3.5
    • Version 2.3.2
    • Version 2.3.1
    • Version 2.3.0
    • Version 2.1.4
    • Version 2.1.3
    • Version 2.1.0
    • Version 2.0.0
Change +