1 | import ExpoFaceDetector from './ExpoFaceDetector';
|
2 | declare type Point = {
|
3 | x: number;
|
4 | y: number;
|
5 | };
|
6 | export declare type FaceFeature = {
|
7 | bounds: {
|
8 | size: {
|
9 | width: number;
|
10 | height: number;
|
11 | };
|
12 | origin: Point;
|
13 | };
|
14 | smilingProbability?: number;
|
15 | leftEarPosition?: Point;
|
16 | rightEarPosition?: Point;
|
17 | leftEyePosition?: Point;
|
18 | leftEyeOpenProbability?: number;
|
19 | rightEyePosition?: Point;
|
20 | rightEyeOpenProbability?: number;
|
21 | leftCheekPosition?: Point;
|
22 | rightCheekPosition?: Point;
|
23 | leftMouthPosition?: Point;
|
24 | mouthPosition?: Point;
|
25 | rightMouthPosition?: Point;
|
26 | bottomMouthPosition?: Point;
|
27 | noseBasePosition?: Point;
|
28 | yawAngle?: number;
|
29 | rollAngle?: number;
|
30 | faceID?: number;
|
31 | };
|
32 | declare type ValuesOf<T extends any[]> = T[number];
|
33 | export declare type FaceDetectorMode = string[];
|
34 | export declare type FaceDetectorLandmarks = ValuesOf<typeof ExpoFaceDetector.Landmarks>;
|
35 | export declare type FaceDetectorClassifications = ValuesOf<typeof ExpoFaceDetector.Classifications>;
|
36 | export interface Image {
|
37 | uri: string;
|
38 | width: number;
|
39 | height: number;
|
40 | orientation: number;
|
41 | }
|
42 | export declare type DetectionOptions = {
|
43 | mode?: FaceDetectorMode;
|
44 | detectLandmarks?: FaceDetectorLandmarks;
|
45 | runClassifications?: FaceDetectorClassifications;
|
46 | };
|
47 | export declare function detectFacesAsync(uri: string, options?: DetectionOptions): Promise<{
|
48 | faces: FaceFeature[];
|
49 | image: Image;
|
50 | }>;
|
51 | export declare const Constants: {
|
52 | Mode: any;
|
53 | Landmarks: any;
|
54 | Classifications: any;
|
55 | };
|
56 | export {};
|