Class Facemark
Abstract base class for all facemark models.
All facemark models in OpenCV are derived from the abstract base class Facemark, which provides a unified access to all facemark algorithms in OpenCV. To utilize this API in your program, please take a look at the @ref tutorial_table_of_content_facemark
Inheritance
System.Object
Facemark
Implements
Inherited Members
Namespace: OpenCvSharp.Face
Assembly: OpenCvSharp.dll
Syntax
public abstract class Facemark : Algorithm, ICvPtrHolder
Methods
| Improve this Doc View SourceFit(InputArray, InputArray, out Point2f[][])
Trains a Facemark algorithm using the given dataset.
Declaration
public virtual bool Fit(InputArray image, InputArray faces, out Point2f[][] landmarks)
Parameters
Type | Name | Description |
---|---|---|
InputArray | image | Input image. |
InputArray | faces | Output of the function which represent region of interest of the detected faces. Each face is stored in cv::Rect container. |
OpenCvSharp.Point2f[][] | landmarks | The detected landmark points for each faces. |
Returns
Type | Description |
---|---|
System.Boolean |
LoadModel(String)
A function to load the trained model before the fitting process.
Declaration
public virtual void LoadModel(string model)
Parameters
Type | Name | Description |
---|---|---|
System.String | model | A string represent the filename of a trained model. |