| Face Engine SDK 5.7.0 A face detection, recognition and tracking engine.

IGlassesEstimator.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(IGlassesEstimator);
12 #endif
13
22 enum class GlassesEstimation: uint8_t{
23 NoGlasses,
24 EyeGlasses,
25 SunGlasses,
26 EstimationError
27 };
28
33 struct IGlassesEstimator : IRefCounted {
41 virtual ResultValue<FSDKError, GlassesEstimation>
42 estimate(const Image& warp) const noexcept = 0;
43
54 virtual Result<FSDKError>
55 estimate(
56 Span<const Image> warps,
57 Span<GlassesEstimation> glassesEstimations) const noexcept = 0;
58
69 virtual Result<FSDKError>
70 validate(
71 Span<const Image> warps,
72 Span<Result<FSDKError>> errors) const noexcept = 0;
73 };
74
75 } // 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
DECLARE_SMARTPTR
#define DECLARE_SMARTPTR(X)
Smart ptr declaration helper macro.
Definition: Def.h:59
fsdk::IGlassesEstimator::estimate
virtual Result< FSDKError > estimate(Span< const Image > warps, Span< GlassesEstimation > glassesEstimations) const noexcept=0
Checks if people are wearing glasses or not for multiple warped images in a single estimate function ...
fsdk
SDK namespace.
Definition: IAGSEstimator.h:8
fsdk::GlassesEstimation
GlassesEstimation
Glasses estimation enum.
Definition: IGlassesEstimator.h:22
fsdk::IGlassesEstimator
Glasses estimator interface.
Definition: IGlassesEstimator.h:33
fsdk::IGlassesEstimator::validate
virtual Result< FSDKError > validate(Span< const Image > warps, Span< Result< FSDKError >> errors) const noexcept=0
Validate input of multiple frames in a single function call.
fsdk::GlassesEstimation::NoGlasses
@ NoGlasses
Person is not wearing glasses.
fsdk::Result
A structure that encapsulates an action result enumeration.
Definition: Result.h:30
fsdk::IGlassesEstimator::estimate
virtual ResultValue< FSDKError, GlassesEstimation > estimate(const Image &warp) const noexcept=0
fsdk::Image
Image.
Definition: Image.h:38
fsdk::IRefCounted
Base strong reference counted object interface.
Definition: IRefCounted.h:36
fsdk::ResultValue
Addon for Result to output some value aside the result. Specialization for copiable types.
Definition: ResultValue.h:25