The Mobile Vision API is now a part of ML Kit. We strongly encourage you to try it out, as it comes with new capabilities like on-device image labeling! Also, note that we ultimately plan to wind down the Mobile Vision API, with all new on-device ML capabilities released via ML Kit. Feel free to reach out to Firebase support for help.

GMVFocusingDataOutput Class

GMVFocusingDataOutput Class Reference

Overview

A concrete subclass of GMVDataOutput.

This dataOutput allows clients to select the item on which GMVFeature to focus.

Inherits GMVDataOutput.

Inherited by GMVLargestFaceFocusingDataOutput.

Instance Method Summary

(instancetype) - initWithDetector:
 Designated initializer. More...
 
(void) - receivedResults:
 Subclasses need to override these methods. More...
 
(void) - cleanup
 Clean up resources. More...
 

Property Summary

id< GMVOutputTrackerDelegatetrackerDelegate
 Post processing delegation. More...
 
id< GMVFocusingDataOutputDelegatedataDelegate
 Data output delegate. More...
 
AVCaptureDevicePosition captureDevicePosition
 Sets the camera device position to help calculate image rotation. More...
 
CGSize previewFrameSize
 The video frame preview size. More...
 
NSUInteger maxFrameGap
 The maximum allowable frames must pass without detecting a specific feature before delegate is notified the feature is no longer available. More...
 

Method Detail

- (instancetype) initWithDetector: (GMVDetector *)  NS_DESIGNATED_INITIALIZER

Designated initializer.

Parameters
detectoruse to run detection.
- (void) receivedResults: (NSArray< __kindof GMVFeature * > *)  results

Subclasses need to override these methods.

Detected GMVFeature results.

Parameters
resultsThe full detection results.
- (void) cleanup

Clean up resources.

Property Detail

- (id<GMVOutputTrackerDelegate>) trackerDelegate
readwritenonatomicstrong

Post processing delegation.

The trackerDelegate is referenced strongly. Call -cleanup to free up internal resources.

- (id<GMVFocusingDataOutputDelegate>) dataDelegate
readwritenonatomicweak

Data output delegate.

- (AVCaptureDevicePosition) captureDevicePosition
readwritenonatomicassigninherited

Sets the camera device position to help calculate image rotation.

If not provided, it will try to retrieve position info through AVCaptureConnection.

- (CGSize) previewFrameSize
readnonatomicassigninherited

The video frame preview size.

The value is used to normalize display properties.

- (NSUInteger) maxFrameGap
readwritenonatomicassigninherited

The maximum allowable frames must pass without detecting a specific feature before delegate is notified the feature is no longer available.

The value is default to 3.