29 lines
499 B
Dart
29 lines
499 B
Dart
import 'package:flutter/material.dart';
|
|
|
|
enum FaceHintType {
|
|
noFace,
|
|
tooDark,
|
|
tooClose,
|
|
tooFar,
|
|
notCentered,
|
|
lookStraight,
|
|
holdStill,
|
|
good,
|
|
}
|
|
|
|
class FaceFeedback {
|
|
final FaceHintType type;
|
|
final String message;
|
|
final double quality; // 0..1 (used for progress ring)
|
|
final Color borderColor;
|
|
|
|
FaceFeedback({
|
|
required this.type,
|
|
required this.message,
|
|
required this.quality,
|
|
required this.borderColor,
|
|
});
|
|
|
|
bool get isGood => type == FaceHintType.good;
|
|
}
|