Face Engine SDK  5.21.0
A face detection, recognition and tracking engine.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
ILivenessDepthEstimator.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(ILivenessDepthEstimator);
12 #endif
13 
25  struct DepthRange {
26  float min = 600.f;
27  float max = 3000.f;
28 
32  bool isOk() const noexcept {
33  return ((min >= 0.f) && (max > min));
34  }
35  };
36 
40  struct DepthEstimation {
41  float score;
42  bool isReal;
43  };
44 
60  virtual Result<FSDKError> estimate(const Image& depth, DepthEstimation& out) const noexcept = 0;
61  };
62 
64 } // namespace fsdk
#define DECLARE_SMARTPTR(X)
Smart ptr declaration helper macro.
Definition: Def.h:56
bool isReal
boolean flag that indicates whether a person is real.
Definition: ILivenessDepthEstimator.h:42
A structure that encapsulates an action result enumeration.
Definition: Result.h:27
Common data types and structures.
Depth range configuration structure in millimeters.
Definition: ILivenessDepthEstimator.h:25
bool isOk() const noexcept
Definition: ILivenessDepthEstimator.h:32
Object system types and interfaces.
Common SDK error codes.
float min
Minimum distance.
Definition: ILivenessDepthEstimator.h:26
Base strong reference counted object interface.
Definition: IRefCounted.h:37
virtual Result< FSDKError > estimate(const Image &depth, DepthEstimation &out) const noexcept=0
Check whether or not depth map corresponds to the real person.
float score
confidence score in [0,1] range. &quot;1&quot; means absolute confidence that the person is real...
Definition: ILivenessDepthEstimator.h:41
Depth estimator interface.
Definition: ILivenessDepthEstimator.h:51
Image.
Definition: Image.h:38
Depth estimator output structure.
Definition: ILivenessDepthEstimator.h:40
float max
Maximum distance.
Definition: ILivenessDepthEstimator.h:27