public final class
HandLandmarker
Performs hand landmarks detection on images.
This API expects a pre-trained hand landmarks model asset bundle. See
MPImage
HandLandmarkerResult
Nested Classes
class | HandLandmarker.HandLandmarkerOptions | Options for setting up an HandLandmarker . |
Fields
public static final Set<Connection> | HAND_CONNECTIONS | |
public static final Set<Connection> | HAND_INDEX_FINGER_CONNECTIONS | |
public static final Set<Connection> | HAND_MIDDLE_FINGER_CONNECTIONS | |
public static final Set<Connection> | HAND_PALM_CONNECTIONS | |
public static final Set<Connection> | HAND_PINKY_FINGER_CONNECTIONS | |
public static final Set<Connection> | HAND_RING_FINGER_CONNECTIONS | |
public static final Set<Connection> | HAND_THUMB_CONNECTIONS |
Public Methods
static HandLandmarker |
createFromBuffer(Context context, ByteBuffer modelBuffer)
Creates a
HandLandmarker instance from a model buffer and the default HandLandmarker.HandLandmarkerOptions . |
static HandLandmarker |
createFromFile(Context context, String modelPath)
Creates a
HandLandmarker instance from a model file and the default HandLandmarker.HandLandmarkerOptions . |
static HandLandmarker |
createFromFile(Context context, File modelFile)
Creates a
HandLandmarker instance from a model file and the default HandLandmarker.HandLandmarkerOptions . |
static HandLandmarker |
createFromOptions(Context context, HandLandmarker.HandLandmarkerOptions landmarkerOptions)
Creates a
HandLandmarker instance from a HandLandmarker.HandLandmarkerOptions . |
HandLandmarkerResult | |
HandLandmarkerResult |
detect(MPImage image, ImageProcessingOptions imageProcessingOptions)
Performs hand landmarks detection on the provided single image.
|
void |
detectAsync(MPImage image, ImageProcessingOptions imageProcessingOptions, long timestampMs)
Sends live image data to perform hand landmarks detection, and the results will be available
via the
OutputHandler.ResultListener provided in the HandLandmarker.HandLandmarkerOptions . |
void |
detectAsync(MPImage image, long timestampMs)
Sends live image data to perform hand landmarks detection with default image processing
options, i.e.
|
HandLandmarkerResult |
detectForVideo(MPImage image, ImageProcessingOptions imageProcessingOptions, long timestampMs)
Performs hand landmarks detection on the provided video frame.
|
HandLandmarkerResult |
detectForVideo(MPImage image, long timestampMs)
Performs hand landmarks detection on the provided video frame with default image processing
options, i.e.
|