DCEFrame
The DCEFrame is the class that stores pixel data and further information.
- Objective-C
- Swift
@interface DCEFrame : NSObjectclass DCEFrame : iImageData
| Method & Property Name | Type/Return Value | Description |
|---|---|---|
bytes |
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. |
format |
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. |
imageData
The property stores the pixel data of the image.
- Objective-C
- Swift
NSData* imageDatavar bytes: Data? { get set }
width
The property stores the pixel width of the image.
- Objective-C
- Swift
NSInteger widthvar width: Int { get set }
height
The property stores the pixel height of the image.
- Objective-C
- Swift
NSInteger heightvar height: Int { get set }
stride
The property stores the stride of the image.
- Objective-C
- Swift
NSInteger stridevar stride: Int { get set }
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 EnumImagePixelFormat
- Objective-C
- Swift
NSInteger pixelFormatvar pixelFormat: Int { get set }
frameID
The property stores the frameID of the frame.
- Objective-C
- Swift
NSInteger frameIDvar frameID: Int { get set }
quality
The property indicates the image quality of the DCEFrame. View more in EnumFrameQuality. User have to enable the frame filter feature to get the quality (high/low) of the DCEFrame. Otherwise, the frame quality will be unknown.
- Objective-C
- Swift
EnumFrameQuality qualityvar quality: EnumFrameQuality { get set }
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.
- Objective-C
- Swift
BOOL isCroppedvar isCropped: Bool { get set }
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.
- Objective-C
- Swift
CGRect cropRegionvar cropRegion: CGRect { get set }
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.
- Objective-C
- Swift
NSInteger orientationvar orientation: Int { get set }

All examples of the orientation
toUIImage
The method converts the image to UIImage.
- Objective-C
- Swift
- (UIImage * _Nullable)toUIImage:(NSError *_Nullable *_Nullable)error;func toUIImage() throws -> UIImage
Return Value
The converted image.
Code Snippet
- Objective-C
- Swift
@property(nonatomic, strong) DCEFrame *dceFrame; /* ... */ [dceFrame toUIImage];var dceFrame:DCEFrame! = nil /* ... */ dceFrame.toUIImage()