detect

abstract fun detect(faceImage: FaceImage, query: FaceDetectionQuery = FaceDetectionQuery(), limit: Int): List<FaceDetector.Face>

Detect faces in the image. This operation should be called on a background thread.

Return

List of faces or empty list if no face is detected.

Parameters

faceImage

BGR raw image with expected face size ratio interval.

query

Query for extra evaluations. It allows for additional processing beyond basic face detection. The default, FaceDetectionQuery, signifies no extra evaluations and is optimized for speed.

limit

Detection stops when number of detected faces reaches limit.

Throws

If DOT Face library with the detection module is not activated or if any of the requested attributes in query requires extra module, which is not activated.