Web Demos

BARCODE READER SDK DEMO

Explore the flexibe barcode reading settings to optimize for your specific usage scenario.

WEB TWAIN SDK DEMO

Try the most popular web scanner features: scan images, import local images and PDF files, edit, save to local, upload to database, and etc.

BARCODE READER JAVASCRIPT DEMO

Transform any camera-equipped devices into real-time, browser-based barcode and QR code scanners.

MRZ SCANNER WEB DEMO

Detects the machine-readable zone of a passport, scans the text, and parses into human-readable data.

APP STORE DEMOS

BARCODE READER SDK FOR IOS

BARCODE READER SDK FOR ANDROID

VIEW MORE DEMOS >
Resource Base
Table of contents

DCEFrame

The DCEFrame is the class that stores pixel data and further information.

@interface DCEFrame : NSObject
Method & Property Name Type/Return Value Description
imageData NSData * The property stores the pixel data of the image.
width NSInteger The property stores the pixel width of the image.
height NSInteger The property stores the pixel height of the image.
stride NSInteger The property stores the stride of the image.
pixelFormat NSInteger The property stores the pixel format of the image.
frameID NSInteger The property stores the frameID of the frame.
quality EnumFrameQuality The property stores the quality of the DCEFrame image. User have to enable the frame filter feature to get the quality (high/low) of the DCEFrame. Otherwise, the frame quality will be unknown.
isCropped BOOL The property stores a boolean value that recording whether the image is cropped. The frames can be cropped if fast mode is enabled.
cropRegion CGRect The property stores a CGRect value that means the crop region of the image (if the image is cropped). If the image is not cropped, the value will be null.
orientation NSInteger The property stores an int value that means the rotation angle of the image. The value is 0, 90, 180 or 270 with depends on the device orientation.
toUIImage UIImage * The method converts the image to UIImage to make it visible on the UI.

imageData

The property stores the pixel data of the image.

NSData* imageData

 

width

The property stores the pixel width of the image.

NSInteger width

 

height

The property stores the pixel height of the image.

NSInteger height

 

stride

The property stores the stride of the image.

NSInteger stride

 

pixelFormat

The property stores the pixel format of the image. The property value is one of the Enumeration value of ImagePixelFormat. Currently, the image output formats of DCEFrame are NV21 or ARGB_8888. View more in Dynamsoft Barcode Reader Enumeration ImagePixelFormat

NSInteger pixelFormat

 

frameID

The property stores the frameID of the frame.

NSInteger frameID

 

quality

The property stores the quality of the DCEFrame image. User have to enable the frame filter feature to get the quality (high/low) of the DCEFrame. Otherwise, the frame quality will be unknown. View more about the frame quality in enumeration EnumFrameQuality.

EnumFrameQuality quality

 

isCropped

The property stores a boolean value that recording whether the image is cropped. The frames can be cropped if fast mode is enabled. Property value true means the image is cropped and false means the image has never been cropped.

BOOL isCropped

 

cropRegion

The property stores a CGRect value that means the crop region of the image (if the image is cropped). If the image is not cropped, the value will be null.

CGRect cropRegion

 

orientation

The property stores an int value that means the rotation angle of the image. The value is 0, 90, 180 or 270, which depends on the device orientation.

NSInteger orientation

getOrientation

All examples of the orientation

 

toUIImage

The method converts the image to UIImage to make it visible on the UI.

- (UIImage*)toUIImage;

Return Value

The converted image.

Code Snippet

  • Objective-C
  • Swift
  1. @property(nonatomic, strong) DCEFrame *dceFrame;
    ...
    [dceFrame toUIImage];
    
  2. var dceFrame:DCEFrame! = nil
    ...
    dceFrame.toUIImage()
    

This page is compatible for:

Version 1.0

Is this page helpful?

YesYes NoNo

In this article:

latest version

  • Latest version
  • Version 2.3.2
  • Version 2.3.1
  • Version 2.1.0
  • Version 2.0.0
  • Version 1.0.3
  • Version 1.0.1
  • Version 1.0.0
Change +
© 2003–2022 Dynamsoft. All rights reserved.
Privacy Statement / Site Map / Home / Purchase / Support