processInputImage method

Future<List<Face>> processInputImage(
  1. InputImage imgFile
)

Implementation

Future<List<Face>> processInputImage(InputImage imgFile) async {
  for (var i = 0; i < 3; i++) {
    final List<Face> faces = await faceDetector.processImage(
      imgFile,
    );
    if (faces.isNotEmpty) {
      return faces;
    }
  }
  return [];
}