Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified leap_lib/LeapJava.jar
Binary file not shown.
Binary file added leap_lib/libLeap.so
Binary file not shown.
Binary file added leap_lib/libLeapJava.so
Binary file not shown.
Binary file added leap_lib/x64/libLeap.so
Binary file not shown.
Binary file added leap_lib/x64/libLeapJava.so
Binary file not shown.
Binary file added leap_lib/x86/libLeap.so
Binary file not shown.
Binary file added leap_lib/x86/libLeapJava.so
Binary file not shown.
4 changes: 2 additions & 2 deletions src/clojure_leap/controller.clj
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
(vec (keep #(try (frame controller %) (catch Exception e nil)) (range history-count))))

(defn ^ScreenList screens [^Controller controller]
(.calibratedScreens controller))
(.locatedScreens controller))

(defn ^Screen screen [^Controller controller]
;; There is a guarantee that there is at least one screen
(first (.calibratedScreens controller)))
(first (.locatedScreens controller)))

(defn connected? [^Controller controller]
(.isConnected controller))
Expand Down
2 changes: 1 addition & 1 deletion src/clojure_leap/finger.clj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
(.count finger-list))

(defn empty? [^FingerList finger-list]
(.empty finger-list))
(.isEmpty finger-list))

;; Finger
;;;;;;;;;;;;;;;
Expand Down
8 changes: 4 additions & 4 deletions src/clojure_leap/frame.clj
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
(.hands frame))

(defn hands? [^Frame frame]
(not (.empty (.hands frame))))
(not (.isEmpty (.hands frame))))

(defn single-hand? [^Frame frame]
(= 1 (.count (.hands frame))))
Expand Down Expand Up @@ -61,7 +61,7 @@
(defn fingers?
"Are there any fingers detected for a given Frame"
[^Frame frame]
(not (.empty (.fingers frame))))
(not (.isEmpty (.fingers frame))))

(defn ^Finger raw-finger [^Frame frame finger-id]
(.finger frame finger-id))
Expand Down Expand Up @@ -92,7 +92,7 @@
(.tools frame))

(defn tools? [^Frame frame]
(not (.empty (.tools frame))))
(not (.isEmpty (.tools frame))))

(defn ^Tool raw-tool [^Frame frame tool-id]
(.tool frame tool-id))
Expand Down Expand Up @@ -123,7 +123,7 @@
(.pointables frame))

(defn pointables? [^Frame frame]
(not (.empty (.pointables frame))))
(not (.isEmpty (.pointables frame))))

(defn ^Pointable raw-pointable [^Frame frame pointable-id]
(.pointable frame pointable-id))
Expand Down
10 changes: 5 additions & 5 deletions src/clojure_leap/hand.clj
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
(.count hand-list))

(defn empty? [^HandList hand-list]
(.empty hand-list))
(.isEmpty hand-list))


;; Hand
Expand All @@ -35,7 +35,7 @@
(defn fingers?
"Are there any fingers detected for a given Hand"
[^Hand hand]
(not (.empty (.fingers hand))))
(not (.isEmpty (.fingers hand))))

(defn ^Finger raw-finger [^Hand hand finger-id]
(.finger hand finger-id))
Expand Down Expand Up @@ -66,7 +66,7 @@
(.tools hand))

(defn tools? [^Hand hand]
(not (.empty (.tools hand))))
(not (.isEmpty (.tools hand))))

(defn ^Tool raw-tool [^Hand hand tool-id]
(.tool hand tool-id))
Expand Down Expand Up @@ -97,7 +97,7 @@
(.pointables hand))

(defn pointables? [^Hand hand]
(not (.empty (.pointables hand))))
(not (.isEmpty (.pointables hand))))

(defn ^Pointable raw-pointable [^Hand hand pointable-id]
(.pointable hand pointable-id))
Expand Down Expand Up @@ -127,7 +127,7 @@
(defn fist?
"Are we detecting a possible fist? - a hand with no fingers/tools/pointables"
[^Hand hand]
(.empty (.pointables hand)))
(.isEmpty (.pointables hand)))

(defn ^Vector direction [^Hand hand]
(.direction hand))
Expand Down
2 changes: 1 addition & 1 deletion src/clojure_leap/tool.clj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
(.count tool-list))

(defn empty? [^ToolList tool-list]
(.empty tool-list))
(.isEmpty tool-list))

;; Tool
;;;;;;;;;;;;;;;
Expand Down