Thanks for downloading Dynamsoft Label Recognizer Package!
Your download will start shortly. If your download does not begin, click here to retry.
DCEImageEditorView
DCEImageEditorView
is the class that enable users to add UI configurations on a static image.
@interface DCEImageEditorView : UIView
Method Name | Description |
---|---|
setOriginalImage |
Set the background image of the view with an original image. |
getOriginalImage |
Get the current backgroud image. |
getDrawingLayer |
Get the DCEDrawingLayer instance with the layer ID. |
createDrawingLayer |
Create a user-defined DCEDrawingLayer instance. |
getSelectedDrawingItem |
Get the selected drawing item. |
setOriginalImage
- (void) setOriginalImage:(ImageData)imageData;
Parameters
imageData
: The imageData
of the image.
Code Snippet
- Objective-C
- Swift
[_imageEditorView setOriginalImage:imageData];
imageEditorView.setOriginalImage(imageData)
getOriginalImage
- (ImageData*) getOriginalImage;
Return Value
The imageData
of the image.
Code Snippet
- Objective-C
- Swift
ImageData* imageData = [imageEditorView getOriginalImage];
let imageData = imageEditorView.getOriginalImage()
getDrawingLayer
- (DCEDrawingLayer*) getDrawingLayer:(NSInteger)id;
Parameters
id
: The id of the drawing layer.
Available ID List
Layer | ID |
---|---|
DDN_LAYER_ID | 1 |
DBR_LAYER_ID | 2 |
DLR_LAYER_ID | 3 |
USER_DEFINED_LAYER_BASE_ID | 100 |
Return Value
The targeting instance of DCEDrawingLayer
.
Code Snippet
- Objective-C
- Swift
DCEDrawingLayer* drawingLayer = [imageEditorView getDrawingLayer:DBR_LAYER_ID];
let drawingLayer = imageEditorView.getDrawingLayer(DBR_LAYER_ID)
createDrawingLayer
- (DCEDrawingLayer*) createDrawingLayer;
Return Value
A user-defined drawing layer.
Code Snippet
- Objective-C
- Swift
DCEDrawingLayer* drawingLayer = [imageEditorView createDrawingLayer];
let drawingLayer = imageEditorView.createDrawingLayer()
getSelectedDrawingItem
- (DrawingItem*) getSelectedDrawingItem;
Return Value
Code Snippet
- Objective-C
- Swift
DrawingItem* item = [imageEditorView getSelectedDrawingItem];
let item = imageEditorView.getSelectedDrawingItem()