P5 Glove finger reading DLL and Unity3d demo
Posted: Tue May 06, 2014 10:29 am
P5GloveDLL
This uses the P5Glove class I wrote for the mouse driver, and compiles it into a DLL. I wrote this so I could read my P5 Glove in Unity3d Pro. Its so basic its not even worth explaining, just drop it into your Unity project and access it (see the Unity sample here for an example of its use if you haven't used DLL's in Unity before). Note this DLL only reads the fingers positions, it doesn't bother with the sensor data from the outdated P5 sensor base.
P5GloveUnityTest
This is a very simple example showing how to use the P5 Glove DLL in Unity. I assume you can probably use other P5 DLL's instead if you'd rather, such as the GlovePIE one (as long as they work for your glove). In it, i've taken the Sixense hand sample and put some very simple code in to make the fingers onscreen bend when you bend the P5 Gloves fingers. I haven't used the Hydra specific components (so no Hydra tracking in the example, just finger motion), so as to make it as simple as possible to understand. Just take a look at the 'P5Fingers.cs' class, and you'll see how simple it is to get finger tracking into your Unity application.
This uses the P5Glove class I wrote for the mouse driver, and compiles it into a DLL. I wrote this so I could read my P5 Glove in Unity3d Pro. Its so basic its not even worth explaining, just drop it into your Unity project and access it (see the Unity sample here for an example of its use if you haven't used DLL's in Unity before). Note this DLL only reads the fingers positions, it doesn't bother with the sensor data from the outdated P5 sensor base.
P5GloveUnityTest
This is a very simple example showing how to use the P5 Glove DLL in Unity. I assume you can probably use other P5 DLL's instead if you'd rather, such as the GlovePIE one (as long as they work for your glove). In it, i've taken the Sixense hand sample and put some very simple code in to make the fingers onscreen bend when you bend the P5 Gloves fingers. I haven't used the Hydra specific components (so no Hydra tracking in the example, just finger motion), so as to make it as simple as possible to understand. Just take a look at the 'P5Fingers.cs' class, and you'll see how simple it is to get finger tracking into your Unity application.