Resource Base
Table of contents

com.dynamsoft.dce.Frame

This page is for Frame Class. Frame parameters store the frame data.

Method Name Type
getData byte[]
getWidth int
getHeight int
getStrides int[]
getFormat int
getFrameId int
isFastFrame boolean
getFastFrameId int
getCropRect Rect
getOrientation int
getOriW int
getOriH int

getData

Get the frame data in byte array.

Java:

Frame frame;
byte[] data = frame.getData();

Kotlin:

var frame: Frame? = null
var data: ByteArray? = frame!!.data

getWidth

Get the frame width in pixels.

Java:

int width = frame.getWidth();

Kotlin:

var width: Int? = frame!!.width

getHeight

Get the frame height in pixels.

Java:

int height = frame.getHeight(); 

Kotlin:

var height: Int? = frame!!.height

getStrides

Get the frame strides.

Java:

int[] strides = frame.getStrides();

Kotlin:

var strides: IntArray? = frame!!.strides

getFormat

Get the frame pixel format.

Java:

int format = frame.getFormat();

Kotlin:

var format: Int? = frame!!.format

getFrameId

Get the frame ID.

int frameid = frame.getFrameId(); 

Kotlin:

var frameid: Int? = frame!!.frameId

isFastFrame

Check whether the fast mode is enabled.

Java:

boolean isfastframe = frame.isFastFrame();

Kotlin:

var isfastframe: Boolean? = frame!!.isFastFrame

getFastFrameId

Get the fast frame (cropped frame) ID.

Java:

int fastframeid = frame.getFastFrameId();

Kotlin:

var fastframeid: Int? = frame!!.fastFrameId

getCropRect

Get the cropped Rect data (Width & height)

Java:

Rect croprect = frame.getCropRect();

Kotlin:

var croprect: Rect? = frame!!.cropRect

getOrientation

Get the orientation (of cropped frame).

Orientation of the frame Value
Vertical 1
Horizontal 2

Java:

int orientation = frame.getOrientation();

Kotlin:

var orientation: Int? = frame!!.getOrientation

getOriW

Get the original width of the cropped frame.

Java:

int originalwidth = frame.getOriW();

Kotlin:

var originalwidth: Int? = frame!!.getOriW

getOriH

Get the original width of the cropped frame.

Java:

int originalheight = frame.getOriH();

Kotlin:

var originalheight: Int? = frame!!.getOriH

This page is compatible for:

Version 1.0

Is this page helpful?

YesYes NoNo

In this article:

latest version

  • Latest version
  • Version 1.0.1
  • Version 1.0
Change +
© 2003–2021 Dynamsoft. All rights reserved.
Privacy Statement / Site Map / Home / Purchase / Support