| class info |
| com.huawei.hms.mlsdk.face.MLFaceShape |
| Represents a facial shape, which contains a set of points that outlines a facial region. Shape types include: TYPE_ALL: The value is 0, representing all shapes of a face. TYPE_FACE: The value is 1, representing the overall facial shape. TYPE_LEFT_EYE: The value is 2, representing the shape of the left eye. TYPE_RIGHT_EYE: The value is 3, representing the shape of the right eye. TYPE_BOTTOM_OF_LEFT_EYEBROW: The value is 4, representing the bottom shape of the left eyebrow. TYPE_BOTTOM_OF_RIGHT_EYEBROW: The value is 5, representing the bottom shape of the right eyebrow. TYPE_TOP_OF_LEFT_EYEBROW: The value is 6, representing the top shape of the left eyebrow. TYPE_TOP_OF_RIGHT_EYEBROW: The value is 7, representing the top shape of the right eyebrow. TYPE_BOTTOM_OF_LOWER_LIP: The value is 8, representing the bottom shape of the lower lip. TYPE_TOP_OF_LOWER_LIP: The value is 9, representing the top shape of the lower lip. TYPE_TOP_OF_UPPER_LIP: The value is 10, representing the top shape of the upper lip. TYPE_BOTTOM_OF_UPPER_LIP: The value is 11, representing the bottom shape of the upper lip. TYPE_BOTTOM_OF_NOSE: The value is 12, representing the bottom shape of the nose. TYPE_BRIDGE_OF_NOSE: The value is 13, representing the shape of the nose bridge. Note: In this document, “left” and “right” refer to the sides you are facing the image, not the sides of the face in the image. |
| Type | Name | Desc |
| int | TYPE_ALL | All shapes of a face. |
| int | TYPE_BOTTOM_OF_LEFT_EYEBROW | Bottom shape of the left eyebrow. |
| int | TYPE_BOTTOM_OF_LOWER_LIP | Bottom shape of the lower lip. |
| int | TYPE_BOTTOM_OF_NOSE | Bottom shape of the nose. |
| int | TYPE_BOTTOM_OF_RIGHT_EYEBROW | Bottom shape of the right eyebrow. |
| int | TYPE_BOTTOM_OF_UPPER_LIP | Bottom shape of the upper lip. |
| int | TYPE_BRIDGE_OF_NOSE | Shape of the nose bridge. |
| int | TYPE_FACE | Overall face shape. |
| int | TYPE_LEFT_EYE | Shape of the left eye. |
| int | TYPE_RIGHT_EYE | Shape of the right eye. |
| int | TYPE_TOP_OF_LEFT_EYEBROW | Top shape of the left eyebrow. |
| int | TYPE_TOP_OF_LOWER_LIP | Top shape of the lower lip. |
| int | TYPE_TOP_OF_RIGHT_EYEBROW | Top shape of the right eyebrow. |
| int | TYPE_TOP_OF_UPPER_LIP | Top shape of the upper lip. |
| Return type | Method name |
| int | getFaceShapeType() |
| List<MLPosition> | getPoints() |
| String | toString() |
| Constant |
| public static final int TYPE_ALL |
| All shapes of a face. |
| Constant value: 0 |
| Constant |
| public static final int TYPE_BOTTOM_OF_LEFT_EYEBROW |
| Bottom shape of the left eyebrow. |
| Constant value: 4 |
| Constant |
| public static final int TYPE_BOTTOM_OF_LOWER_LIP |
| Bottom shape of the lower lip. |
| Constant value: 8 |
| Constant |
| public static final int TYPE_BOTTOM_OF_NOSE |
| Bottom shape of the nose. |
| Constant value: 12 |
| Constant |
| public static final int TYPE_BOTTOM_OF_RIGHT_EYEBROW |
| Bottom shape of the right eyebrow. |
| Constant value: 5 |
| Constant |
| public static final int TYPE_BOTTOM_OF_UPPER_LIP |
| Bottom shape of the upper lip. |
| Constant value: 10 |
| Constant |
| public static final int TYPE_BRIDGE_OF_NOSE |
| Shape of the nose bridge. |
| Constant value: 13 |
| Constant |
| public static final int TYPE_FACE |
| Overall face shape. |
| Constant value: 1 |
| Constant |
| public static final int TYPE_LEFT_EYE |
| Shape of the left eye. |
| Constant value: 2 |
| Constant |
| public static final int TYPE_RIGHT_EYE |
| Shape of the right eye. |
| Constant value: 3 |
| Constant |
| public static final int TYPE_TOP_OF_LEFT_EYEBROW |
| Top shape of the left eyebrow. |
| Constant value: 6 |
| Constant |
| public static final int TYPE_TOP_OF_LOWER_LIP |
| Top shape of the lower lip. |
| Constant value: 9 |
| Constant |
| public static final int TYPE_TOP_OF_RIGHT_EYEBROW |
| Top shape of the right eyebrow. |
| Constant value: 7 |
| Constant |
| public static final int TYPE_TOP_OF_UPPER_LIP |
| Top shape of the upper lip. |
| Constant value: 11 |
| Method |
| public int getFaceShapeType() |
| Obtains the facial shape type. |
Return
| Type | desc |
| int | Returns the facial shape type. |
| Method |
| public List<MLPosition> getPoints() |
| Obtains all points of the current shape. |
Return
| Type | desc |
| List<MLPosition> | Returns all points of the current shape. |
| Method |
| public String toString() |
| Converts the current instance into a character string. |
Return
| Type | desc |
| String | Character string of the current instance. |