Table of Contents

Method DetectAsync

Namespace
LMKit.Vision
Assembly
LM-Kit.NET.dll

DetectAsync(ImageBuffer, CancellationToken)

Finds the faces in an image, on a worker thread.

public Task<IReadOnlyList<DetectedFace>> DetectAsync(ImageBuffer image, CancellationToken cancellationToken = default)

Parameters

image ImageBuffer

The image. Any pixel format; it is read as RGB.

cancellationToken CancellationToken

A token to cancel the detection.

Returns

Task<IReadOnlyList<DetectedFace>>

The faces found, the most confident first, in the image's pixels.

Exceptions

ArgumentNullException

image is null.

OperationCanceledException

The detection was cancelled.

Share