Platforms to show: All Mac Windows Linux Cross-Platform
VNImageRequestHandlerMBS class
| Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
| class | Vision | MBS MacFrameworks Plugin | 19.4 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Instantiate this handler to perform Vision requests on a single image. You specify the image and, optionally, a completion handler at the time of creation, and call performRequests to begin executing the request.
This is an abstract class. You can't create an instance, but you can get one from various plugin functions.
- property Handle as Integer
- 4 methods
- method Constructor Private
- method Destructor
- method performRequests(requests() as VNRequestMBS, byref error as NSErrorMBS) as Boolean
- method performRequestsAsync(requests() as VNRequestMBS, DelegateHandler as VNPerformRequestsCompletedMBS = nil, tag as variant = nil)
- 9 shared methods
- shared method RequestWithCGImage(CGImage as CGImageMBS, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method RequestWithCIImage(CIImage as Variant, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method RequestWithCVPixelBuffer(CVPixelBuffer as Variant, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method RequestWithData(Data as MemoryBlock, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method RequestWithFile(File as FolderItem, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method RequestWithPicture(Picture as Picture, orientation as Integer = 0, Options as Dictionary = nil) as VNImageRequestHandlerMBS
- shared method VNImageOptionCameraIntrinsics as String
- shared method VNImageOptionCIContext as String
- shared method VNImageOptionProperties as String
- 8 constants
Orientations
| Constant | Value | Description |
|---|---|---|
| kOrientationDown | 3 |
The encoded image data is rotated 180° from the image's intended display orientation. |
| kOrientationDownMirrored | 4 |
The encoded image data is vertically flipped from the image's intended display orientation. |
| kOrientationLeft | 8 |
The encoded image data is rotated 90° clockwise from the image's intended display orientation. |
| kOrientationLeftMirrored | 5 |
The encoded image data is horizontally flipped and rotated 90° counter-clockwise from the image's intended display orientation. |
| kOrientationRight | 6 |
The encoded image data is rotated 90° clockwise from the image's intended display orientation. |
| kOrientationRightMirrored | 7 |
The encoded image data is horizontally flipped and rotated 90° clockwise from the image's intended display orientation. |
| kOrientationUp | 1 |
The encoded image data matches the image's intended display orientation. |
| kOrientationUpMirrored | 2 |
The encoded image data is horizontally flipped from the image's intended display orientation. |
This class has no sub classes.
Blog Entries
- Segment documents in images for Xojo
- MBS Xojo Plugins, version 23.2pr1
- MBS Xojo Plugins, version 22.3pr3
- Vision Framework for Xojo
Xojo Developer Magazine
Release notes
- Version 23.2
- Fixed a memory leak in VNTargetedImageRequestMBS, VNSequenceRequestHandlerMBS and VNImageRequestHandlerMBS when passing in a Xojo picture.
- Version 22.3
- Fixed a problem with performRequestsAsync crashing in VNImageRequestHandlerMBS class when used in thread.
Some methods using this class:
- VNInstanceMaskObservationMBS.generateMaskedImageOfInstances(Instances as NSIndexSetMBS, requestHandler as VNImageRequestHandlerMBS, croppedToInstancesExtent as Boolean, byref Error as NSErrorMBS) as Variant
- VNInstanceMaskObservationMBS.generateScaledMaskForImageForInstances(Instances as NSIndexSetMBS, requestHandler as VNImageRequestHandlerMBS, byref Error as NSErrorMBS) as Variant
Some examples using this class:
- /AVFoundation/Live Barcode Detection with Vision/Live Barcode Detection with Vision
- /MacFrameworks/DetectDocumentSegmentationRequest
- /MacFrameworks/Vision/Vision Detection
- /MacFrameworks/Vision/Vision Object Detection/Mask Detection
- /MacFrameworks/Vision/Vision Object Detection/Saliency Image Requests
- /MacFrameworks/Vision/Vision Object Detection/Text Recognition
- /MacFrameworks/Vision/Vision Object Detection/Vision Object Detection
Some related classes:
- class CGImageMBS
- class CIContextMBS
- class NSErrorMBS
- class NSIndexSetMBS
- class VNInstanceMaskObservationMBS
- class VNRequestMBS
- class VNSequenceRequestHandlerMBS
- class VNTargetedImageRequestMBS
The items on this page are in the following plugins: MBS MacFrameworks Plugin.
VNImageRegistrationRequestMBS - VNImageTranslationAlignmentObservationMBS