Modifier

Partager via


VNRequest.GetResults<T> Method

Definition

Gets the detected objects, as an array of the specified subclass of VNObservation.

public virtual T[] GetResults<T> () where T : Vision.VNObservation;
abstract member GetResults : unit -> 'T[] (requires 'T :> Vision.VNObservation)
override this.GetResults : unit -> 'T[] (requires 'T :> Vision.VNObservation)

Type Parameters

T

The subclass of VNObservation produced.

Returns

T[]

Remarks

The following example shows how one might retrieve the results of a VNDetectFaceRectanglesRequest:

var rs = request.GetResults<VNFaceObservation>();
foreach (var fo in rs)
{
   // ... etc ...

Applies to