Thanks for downloading Dynamsoft Barcode Reader Package!
Your download will start shortly. If your download does not begin, click here to retry.
DSVideoFrameTag
The DSVideoFrameTag
class represents a video frame tag, which is a type of image tag that is used to store additional information about a video frame. It inherits from the DSImageTag
class and adds additional attributes and methods specific to video frames.
Definition
Assembly: DynamsoftCore.framework
- Objective-C
- Swift
@interface DSVideoFrameTag : DSImageTage
class VideoFrameTag : ImageTag
Attribute Summaries
Attributes | Type | Description |
---|---|---|
quality |
DSVideoFrameQuality | The quality of the video frame. |
isCropped |
BOOL | Indicates whether the video frame is cropped. |
cropRegion |
CGRect | The region based on which the original frame was cropped. If isCropped is false, the region covers the entire original image. |
originalWidth |
NSInteger | The original width of the video frame before any cropping. |
originalHeight |
NSInteger | The original height of the video frame before any cropping. |
Method Summaries
Method | Description |
---|---|
initWithImageId |
The constructor of DSVideoFrameTag . |
Attribute Details
quality
The quality of the video frame.
- Objective-C
- Swift
@property (nonatomic, assign) DSVideoFrameQuality quality;
var quality: EnumVideoFrameQuality { get set }
isCropped
Whether the video frame is cropped.
- Objective-C
- Swift
@property (nonatomic, assign) BOOL isCropped;
var isCropped: Bool { get set }
cropRegion
The region based on which the original frame was cropped. If isCropped
is false, the region covers the entire original image.
- Objective-C
- Swift
@property (nonatomic, assign) CGRect cropRegion;
var cropRegion: CGRect { get set }
originalWidth
The original width of the video frame.
- Objective-C
- Swift
@property (nonatomic, assign) NSInteger originalWidth;
var originalWidth: Int { get set }
originalHeight
The original height of the video frame.
- Objective-C
- Swift
@property (nonatomic, assign) NSInteger originalHeight;
var originalHeight: Int { get set }
Method Details
initWithImageId
The constructor of DSVideoFrameTag
.
- Objective-C
- Swift
- (instancetype)initWithImageId:(NSInteger)imageId quality:(DSVideoFrameQuality)quality isCropped:(BOOL)isCropped cropRegion:(CGRect)cropRegion originalWidth:(NSInteger)originalWidth originalHeight:(NSInteger)originalHeight;
init(imageId: Int, quality: EnumVideoFrameQuality, isCropped: Bool, cropRegion: CGRect, originalWidth: Int, originalHeight: Int)
Parameters
imageId
: The image ID of the video frame.
quality
: The quality of the video frame.
isCropped
: Whether the video frame is cropped.
cropRegion
: The crop region of the video frame.
originalWidth
: The original width of the video frame.
originalHeight
: The original height of the video frame.
Return Value
An instance of the DSVideoFrameTag
.
Code Snippet
- Objective-C
- Swift
DSVideoFrameTag *videoFrameTag = [[DSVideoFrameTag alloc] initWithImageId:imageId quality:quality isCropped:isCropped cropRegion:cropRegion originalWidth:originalWidth originalHeight:originalHeight];
let videoFrameTag = VideoFrameTag(imageId: imageId, quality: quality, isCropped: isCropped, cropRegion: cropRegion, originalWidth: originalWidth, originalHeight: originalHeight)