4.2.2.7. FaceDetector

Inherits from NSObject Declared in STFaceProFaceDetector.h

Overview

顔検知クラス

Tasks

delegate property

– createWithModelPath:config:

– detectWithInputImage:faceOrientation:

– detectWithInputImage:faceOrientation:resultBlock:

Properties

delegate

プロトコルプロキシオブジェクト

@property (nonatomic, weak) id<STFaceProFaceDetectorDelegate> delegate

Discussion

プロトコルプロキシオブジェクト

Declared In

  • STFaceProFaceDetector.h

Instance Methods

createWithModelPath:config:

モデルファイルをロードして、検知ツールを作成します。

- (STFaceProApiResult)createWithModelPath:(NSString *)*modelPath* config:(STFaceProDetectorConfig)*detectorConfig*

Parameters

modelPath アライメントモデルファイルが配置されているパス

detectorConfig 検知ツールの構成オプションを設定します。デフォルト設定は STFaceProDetectorConfig_LARGE_FACE。

Discussion

モデルファイルをロードして、検知ツールを作成します。

Declared In

  • STFaceProFaceDetector.h

detectWithInputImage:faceOrientation:

画像データのフレームを入力すると、顔枠や特徴点を含む情報がプロトコルエージェントを通して返されます。連続フレームの場合に一般的に使用されます。

- (STFaceProApiResult)detectWithInputImage:(void *)*inputImage* faceOrientation:(STFaceProFaceOrientaion)*faceOrientation*

Parameters

inputImage 画像データのフレームを入力

faceOrientation フレーム画像の向き。顔が上向きの状態の画像を使用することを推奨します。

Discussion

画像データのフレームを入力すると、顔枠や特徴点を含む情報がプロトコルエージェントを通して返されます。連続フレームの場合に一般的に使用されます。

Declared In

  • STFaceProFaceDetector.h

detectWithInputImage:faceOrientation:resultBlock:

画像データのフレームを入力すると、顔枠や特徴点を含む情報がブロックを通して返されます。単一フレームの場合に一般的に使用されます。

- (STFaceProApiResult)detectWithInputImage:(void *)*inputImage* faceOrientation:(STFaceProFaceOrientaion)faceOrientation resultBlock:(void ( ^ ) ( void *detectionResult , void *landMarks , int faceCount ))*resultBlock*

Parameters

inputImage 画像データのフレームを入力

faceOrientation フレーム画像の向き。顔が上向きの状態の画像を使用することを推奨します。

resultBlock 検知された顔フレーム、特徴点の配列、および顔の数を出力します。

Discussion

画像データのフレームを入力すると、顔枠や特徴点を含む情報がブロックを通して返されます。単一フレームの場合に一般的に使用されます。

Declared In

  • STFaceProFaceDetector.h

最終更新