Face Engine SDK  5.8.0
A face detection, recognition and tracking engine.
ILivenessOneShotRGBEstimator.h
1 #pragma once
2 
3 #include <fsdk/IObject.h>
4 #include <fsdk/FSDKError.h>
5 #include <fsdk/Optional.h>
6 #include <fsdk/Types.h>
7 
8 namespace fsdk {
9 
10 #ifndef DOXYGEN_SHOULD_SKIP_THIS
11  DECLARE_SMARTPTR(ILivenessOneShotRGBEstimator);
12 #endif
13 
20  enum class State {
21  Alive = 0,
22  Fake,
23  Unknown
24  };
25 
26  float score;
28  float qualityScore;
29  };
30 
48  const Image& image,
49  const Detection& detection,
50  const Landmarks5& landmarks5,
51  LivenessOneShotRGBEstimation& estimation,
52  const float qualityThreshold = -1.f) const noexcept = 0;
53 
69  Span<const Image> images,
70  Span<const Detection> detections,
71  Span<const Landmarks5> landmarks5,
73  const float qualityThreshold = -1.f,
74  LivenessOneShotRGBEstimation* aggregation = nullptr) const noexcept = 0;
75 
88  virtual Result<FSDKError>
90  Span<const Image> images,
91  Span<const Detection> detections,
92  Span<const Landmarks5> landmarks5,
93  Span<Result<FSDKError>> errors) const noexcept = 0;
94  };
95 
96 } // namespace fsdk
fsdk::Span
Span. @detail Not owning data view. It incapsulated pointer to the continuous array with one or more ...
Definition: Span.h:15
fsdk::LivenessOneShotRGBEstimation
Liveness OneShotRGB estimation structure.
Definition: ILivenessOneShotRGBEstimator.h:19
fsdk::FSDKError
FSDKError
Common SDK error codes.
Definition: FSDKError.h:17
fsdk::LivenessOneShotRGBEstimation::State::Fake
@ Fake
The person on image is fake (photo, printed image)
DECLARE_SMARTPTR
#define DECLARE_SMARTPTR(X)
Smart ptr declaration helper macro.
Definition: Def.h:59
fsdk::LivenessOneShotRGBEstimation::State::Unknown
@ Unknown
The liveness status of person on image is Unknown.
fsdk::ILivenessOneShotRGBEstimator::estimate
virtual Result< FSDKError > estimate(Span< const Image > images, Span< const Detection > detections, Span< const Landmarks5 > landmarks5, Span< LivenessOneShotRGBEstimation > estimations, const float qualityThreshold=-1.f, LivenessOneShotRGBEstimation *aggregation=nullptr) const noexcept=0
OneShot RGB Liveness estimation.
fsdk
SDK namespace.
Definition: IAGSEstimator.h:8
fsdk::ILivenessOneShotRGBEstimator::estimate
virtual Result< FSDKError > estimate(const Image &image, const Detection &detection, const Landmarks5 &landmarks5, LivenessOneShotRGBEstimation &estimation, const float qualityThreshold=-1.f) const noexcept=0
OneShot RGB Liveness estimation.
fsdk::LivenessOneShotRGBEstimation::qualityScore
float qualityScore
Liveness quality score.
Definition: ILivenessOneShotRGBEstimator.h:28
fsdk::LivenessOneShotRGBEstimation::state
State state
Liveness status.
Definition: ILivenessOneShotRGBEstimator.h:27
fsdk::LivenessOneShotRGBEstimation::State::Alive
@ Alive
The person on image is real.
fsdk::Landmarks
Face landmarks template structure.
Definition: Landmarks.h:20
fsdk::LivenessOneShotRGBEstimation::State
State
Definition: ILivenessOneShotRGBEstimator.h:20
fsdk::ILivenessOneShotRGBEstimator::validate
virtual Result< FSDKError > validate(Span< const Image > images, Span< const Detection > detections, Span< const Landmarks5 > landmarks5, Span< Result< FSDKError >> errors) const noexcept=0
Validate input of multiple frames in a single function call.
fsdk::Detection
Detection structure. @detail Stores a detected bounding box within a source image rect.
Definition: Detection.h:10
fsdk::Result
A structure that encapsulates an action result enumeration.
Definition: Result.h:30
fsdk::ILivenessOneShotRGBEstimator
OneShot RGB Liveness estimator interface.
Definition: ILivenessOneShotRGBEstimator.h:35
fsdk::Image
Image.
Definition: Image.h:38
fsdk::IRefCounted
Base strong reference counted object interface.
Definition: IRefCounted.h:36
fsdk::LivenessOneShotRGBEstimation::score
float score
Estimation score.
Definition: ILivenessOneShotRGBEstimator.h:26