LCBestShotDelegate
Objective-C
@protocol LCBestShotDelegate <NSObject>
Swift
protocol LCBestShotDelegate : NSObjectProtocol
Delegate of the best shot detector.
-
Called when a face is detected in the shot.
Declaration
Objective-C
- (void)detectionRect:(CGRect)rect inFrameSize:(CGSize)frameSize;
Swift
func detectionRect(_ rect: CGRect, inFrameSize frameSize: CGSize)
Parameters
rect
Detection area.
frameSize
Frame size.
-
Called when the best shot is found.
Declaration
Objective-C
- (BOOL)bestShot:(nonnull LCBestShotModel *)bestShot;
Swift
func bestShot(_ bestShot: LCBestShotModel) -> Bool
Parameters
bestShot
The best shot of the face.
Return Value
Return true, if the new best shots are no longer needed.
-
Called when the best shots are collected.
Declaration
Objective-C
- (BOOL)multipartBestShots:(nonnull NSArray<LCBestShotModel *> *)bestShots;
Swift
func multipartBestShots(_ bestShots: [LCBestShotModel]) -> Bool
Parameters
bestShots
The list of best shot of the face.
Return Value
Return true, if the new best shots are no longer needed.
-
Called if an error has occurred.
Declaration
Objective-C
- (void)bestShotError:(nonnull NSError *)error;
Swift
func bestShotError(_ error: any Error)
Parameters
error
Error.
-
Called when interactions finished.
Declaration
Objective-C
- (void)interactionsFinishWith: (nonnull NSArray<LCInteractionFrameInfo *> *)interactionFrames;
Swift
func interactionsFinish(with interactionFrames: [LCInteractionFrameInfo])
Parameters
interactionFrames
List of frames of completed actions and their names
-
Called if check for liveness is active.
Declaration
Objective-C
- (void)livenessIsActive:(BOOL)isActive;
Swift
optional func livenessIsActive(_ isActive: Bool)
Parameters
isActive
true if check for liveness is currently carried out.