(bind-func get_hand_data
(lambda (frame:astra_handframe_t data:astra_handpoint_X* print:i1)
(letz ((hand:astra_handpoint_X* null)
(coord:<i32,i32>* null)
(i:i32 0)
(ptr:i32* null)
(handCount:i32 0))
(astra_handframe_get_hand_count frame (ref handCount))
(astra_handframe_copy_hands frame (convert data))
(if print
(dotimes (i handCount)
(set! hand (pref-ptr data i))
(set! coord (tref-ptr hand 2))
(if (and (> (tref hand 0) 0) (= (tref hand 1) 2))
(println "hand id:" (tref hand 0) "status:" (tref hand 1) "x:" (tref coord 0) "y:" (tref coord 1)))))
handCount)))