From 9356dfcd4635c926e8af5e5b61bad643f74ea5a9 Mon Sep 17 00:00:00 2001 From: Prianka Liz Kariat Date: Thu, 1 Jun 2023 16:53:32 +0530 Subject: [PATCH] Updated MPPHandLandmarker.h to return the hand connections via class mathods --- .../sources/MPPHandLandmarker.h | 60 +++++++++++++------ 1 file changed, 42 insertions(+), 18 deletions(-) diff --git a/mediapipe/tasks/ios/vision/hand_landmarker/sources/MPPHandLandmarker.h b/mediapipe/tasks/ios/vision/hand_landmarker/sources/MPPHandLandmarker.h index 4135b647f..5149ec0ac 100644 --- a/mediapipe/tasks/ios/vision/hand_landmarker/sources/MPPHandLandmarker.h +++ b/mediapipe/tasks/ios/vision/hand_landmarker/sources/MPPHandLandmarker.h @@ -29,24 +29,6 @@ NS_ASSUME_NONNULL_BEGIN NS_SWIFT_NAME(HandLandmarker) @interface MPPHandLandmarker : NSObject -/** The connections between the landmarks in the palm. */ -@property(nonatomic, readonly) NSArray *handPalmConnections; - -/** The connections between the landmarks in the index finger. */ -@property(nonatomic, readonly) NSArray *handIndexFingerConnections; - -/** The connections between the landmarks in the middle finger. */ -@property(nonatomic, readonly) NSArray *handMiddleFingerConnections; - -/** The connections between the landmarks in the ring finger. */ -@property(nonatomic, readonly) NSArray *handRingFingerConnections; - -/** The connections between the landmarks in the pinky. */ -@property(nonatomic, readonly) NSArray *handPinkyConnections; - -/** The connections between all the landmarks in the hand. */ -@property(nonatomic, readonly) NSArray *handConnections; - /** * Creates a new instance of `MPPHandLandmarker` from an absolute path to a model asset bundle * stored locally on the device and the default `MPPHandLandmarkerOptions`. @@ -174,6 +156,48 @@ NS_SWIFT_NAME(HandLandmarker) - (instancetype)init NS_UNAVAILABLE; +/** + * Returns the connections between the landmarks in the palm. + * + * @return An array of connections between the landmarks in the palm. + */ ++ (NSArray *)handPalmConnections; + +/** + * Returns the connections between the landmarks in the index finger. + * + * @return An array of connections between the landmarks in the index finger. + */ ++ (NSArray *)handIndexFingerConnections; + +/** + * Returns the connections between the landmarks in the middle finger. + * + * @return An array of connections between the landmarks in the middle finger. + */ ++ (NSArray *)handMiddleFingerConnections; + +/** + * Returns the connections between the landmarks in the ring finger. + * + * @return An array of connections between the landmarks in the ring finger. + */ ++ (NSArray *)handRingFingerConnections; + +/** + * Returns the connections between the landmarks in the pinky. + * + * @return An array of connections between the landmarks in the pinky. + */ ++ (NSArray *)handPinkyConnections; + +/** + * Returns the connections between all the landmarks in the hand. + * + * @return An array of connections between all the landmarks in the hand. + */ ++ (NSArray *)handConnections; + + (instancetype)new NS_UNAVAILABLE; @end