public class KEDetectedFace extends DetectedFace
| Modifier and Type | Field and Description |
|---|---|
protected FacialKeypoint[] |
keypoints
A list of detected facial keypoints.
|
bounds, confidence, facePatch| Constructor and Description |
|---|
KEDetectedFace()
Default constructor
|
KEDetectedFace(Rectangle bounds,
FImage patch,
FacialKeypoint[] keypoints,
float confidence)
Construct with parameters.
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
binaryHeader()
Header for binary input.
|
FacialKeypoint |
getKeypoint(FacialKeypoint.FacialKeypointType type)
Get a keypoint of the specified type.
|
FacialKeypoint |
getKeypointInterpolated(FacialKeypoint.FacialKeypointType type)
Get a keypoint of the specified type, interpolating the position if the
internal model doesn't have a matching point.
|
FacialKeypoint[] |
getKeypoints() |
void |
readBinary(DataInput in)
Read internal state from in.
|
void |
writeBinary(DataOutput out)
Write the content of this as binary to out.
|
getBounds, getConfidence, getFacePatch, getShape, setBounds, setConfidence, setFacePatchprotected FacialKeypoint[] keypoints
public KEDetectedFace()
public KEDetectedFace(Rectangle bounds, FImage patch, FacialKeypoint[] keypoints, float confidence)
bounds - the bounds rectangle in the detection imagepatch - the patchkeypoints - the detected facial keypoints.confidence - the confidence of detectionpublic FacialKeypoint getKeypoint(FacialKeypoint.FacialKeypointType type)
type - the type of keypointpublic FacialKeypoint getKeypointInterpolated(FacialKeypoint.FacialKeypointType type)
FacialKeypoint.FacialKeypointType.MOUTH_CENTER,
FacialKeypoint.FacialKeypointType.EYE_LEFT_CENTER and
FacialKeypoint.FacialKeypointType.EYE_RIGHT_CENTER points are supported iff the
corresponding left and right points are available.type - the type of keypointpublic FacialKeypoint[] getKeypoints()
FacialKeypoints associated with this detectionpublic void writeBinary(DataOutput out) throws IOException
WriteableBinarywriteBinary in interface WriteableBinarywriteBinary in class DetectedFaceout - sink to write toIOException - an error writing to outpublic byte[] binaryHeader()
ReadableBinarybinaryHeader in interface ReadableBinarybinaryHeader in interface WriteableBinarybinaryHeader in class DetectedFacepublic void readBinary(DataInput in) throws IOException
ReadableBinaryreadBinary in interface ReadableBinaryreadBinary in class DetectedFacein - source to read from.IOException - an error reading input