Ultraleap Motion 2 Gemini to OSC
-
I am working on a couple of projects using the Leap Motion 2 controller: parameter modulations and position coordinates for Isadora, and motion capture for Blender. Since the current Gemini drivers don't seem to work with the Leap Motion Actor, I started researching alternative approaches and OSC seemed the best way to transmit the Leap data to both Isadora and Blender.
I thought to document my progress in some posts here hoping it helps other users. Using GitHub Copilot and the Ultraleap SDK, I developed a simple Leap-to-OSC prototype Python script, attached below as a zip (i am unable to upload .py or even .txt documents). It's heavily commented with setup and implementation instructions. You'll need some familiarity with Python and Git to get this running. While I'm not a Python developer, I am familiar with Python structures and working in VS Code. I am certain experienced developers will be horrified by the inefficiencies and overall inelegance of the code.
This script outputs hand positions and orientations:
For each hand detected:
- Determines hand type (left/right)
- Sends position as [x, y, z]
- Sends orientation as quaternion [w, x, y, z]I use Protokol for OSC testing: https://hexler.net/protokol
I've also created a Blender script that receives and can record this information. I think it will be a powerful tool for graphic animation work, camera movement, etc.
My next step is to expand the Leap-to-OSC script with a Tkinter interface featuring status messages and the ability to select between sending all hand tracking data or just fingertips for motion graphics work.
Prototype script here:
It's a zip file as I was unable to upload the .py
-
We have an updated Leap Motion actor coming soon. If you need fast access to it, please open a support ticket, and I can help you out.
-
@dusx said:
If you need fast access to it, please open a support ticket, and I can help you out.
That would be great! I am neck deep in this now and hitting some roadblocks. While I have made headway with the python build based on the prototype here, I would love to be up and running. I have been playing with Touch a bit for my blender workflow and it looks pretty straight forward. Isadora would be the treat, though.
I have opened a ticket.
Thanks,
- J
-
Thanks for the opportunity to work with the new Leap Motion Actor. I really appreciate it. It works flawlessly.
By the looks of it, it is tracking the palm data location and rotation. If I could make a humble request, the one point I find very useful in the ultraleap SDK is the index next distal point (index fingertip). I think it's a useful point for screen drawing and general motion capture for mapping to all kinds of things. I know that the rotation value is not accessible for the fingertips, but I think the position for the index fingertip would open up all kinds of possibilities.