Search Unity

SpaceNavigator support

Discussion in 'Made With Unity' started by imin, Jul 1, 2010.

  1. imin

    imin

    Joined:
    Feb 24, 2010
    Posts:
    29
    Hi,

    we've been developping a small 3DConnexion's SpaceNavigator driver to use in your Unity3D application (ie while executing your application, not when editing it)

    It requires Unity3D Pro and Windows.

    The package is free for the moment and comes with the dll library, a sample project and documentation :

    http://bit.ly/SpaceNavigatorUnity

    Constructive comments are very welcome!
     
  2. bigkahuna

    bigkahuna

    Joined:
    Apr 30, 2006
    Posts:
    5,434
    Very nice, thanks very much! I'll give this a try!
     
  3. kosirm

    kosirm

    Joined:
    Dec 31, 2008
    Posts:
    10
    Thanks!!! Great plugin, hopefully you will develop it further (to use it in editor also and to make it easy to plug to first/third person controller, etc).
    Also thanks for making it available for free!
    BR, Milan
     
  4. Derydoca

    Derydoca

    Joined:
    May 13, 2010
    Posts:
    189
    Awesome! When I first started using Unity I actually looked up the space navigator and mused about it's applications for game developing. Hopefully you expand on this and make it usable inside of the editor. Maybe then I will buy myself one of them ... I also need more desk space. I'm crammed enough as it is now. Thanks for the contribution!
     
  5. cemC

    cemC

    Joined:
    Dec 23, 2010
    Posts:
    214
    is it compitable Unity3d 3.1.0f4 version?
     
  6. Novodantis

    Novodantis

    Joined:
    Nov 12, 2009
    Posts:
    95
    I've always wanted to use mine in the editor, and switching between Max and Unity tends to throw me off somewhat... having it in the editor would be marvellous if at all possible =)

    Good that you can support it in-game though, more games should.
     
  7. Cominu

    Cominu

    Joined:
    Feb 18, 2010
    Posts:
    149
    ImIn you got a private message!
     
  8. HarvesteR

    HarvesteR

    Joined:
    May 22, 2009
    Posts:
    531
    Oh this is so awesome!!

    I have mine sitting here, and, being an input device junkie, I want to use it with every possible software I can think of.
    This one wins though! Runtime support for it beats having it in the editor any day. I can think of a ton of games that can make good use of them...

    Thanks a million!!!

    Oh, and BTW, for those that want SpaceNavigator support in-editor, I've hacked up a simple rig here

    Cheers
     
  9. Claude23

    Claude23

    Joined:
    Aug 6, 2011
    Posts:
    4
    Hi lmln. I just got a spacenavigator and would love to try your 3dconnexion driver but the given link is broken. I would really appreciate if you could update it.
    Thanks and keep the good work!
     
  10. Tinus

    Tinus

    Joined:
    Apr 6, 2009
    Posts:
    437
    Apologies for the bump, but like the above posters I would also be interested in trying out this plugin. :)
     
  11. Tinus

    Tinus

    Joined:
    Apr 6, 2009
    Posts:
    437
    As a note to anybody looking for answers in this thread, here's what I've found so far:

    - I tried using the 3DConnexion beta drivers, since they allow you to create application profiles that send joystick commands. This works, but I think Unity reads the incoming signals wrong. I messed around with this for a while, but there appears to be no way to fix this without going through either Unity's or 3DConnexion's source code to see what's happening. Here's my post on the 3DConnexion forums regarding this issue: http://www.3dconnexion.com/forum/viewtopic.php?p=23755#23755.
    - I solved the issue for my specific project using GlovePIE and PPJoy along with the non-beta 3DConnexion drivers. The setup process for this is a little convoluted (mainly because of PPJoy), but it works well once you're done. Here's the small GlovePIE script that translates the 3dmouse input to joystick input:

    Code (csharp):
    1. //DebugPrint(spaceball.x + ", " + spaceball.y + ", " + spaceball.z);
    2. //DebugPrint(spaceball.Pitch + ", " + spaceball.Yaw + ", " + spaceball.Roll);
    3.  
    4. var.translateRange = 80;
    5. var.rotateRange = 4582;
    6.  
    7. ppjoy.Analog0 = spaceball.x / var.translateRange;
    8. ppjoy.Analog1 = spaceball.y / var.translateRange;
    9. ppjoy.Analog2 = spaceball.z / var.translateRange;
    10. ppjoy.Analog3 = spaceball.Pitch / var.rotateRange;
    11. ppjoy.Analog4 = spaceball.Yaw / var.rotateRange;
    12. ppjoy.Analog6 = spaceball.Roll / var.rotateRange;
    13.  
    14. //DebugPrint(ppjoy.Analog0);
    Depending on your spacenavigator's sensitivity settings you'll need change the values of translateRange and rotateRange. You can find these values by uncommenting the top lines and reading the the largest printed values when you move the navigator around.

    Hope that helps anyone!
     
  12. msl_manni

    msl_manni

    Joined:
    Jul 5, 2011
    Posts:
    272
    Hi Tinus,
    I would like to know if GlovePIE and PPJoy are working with the latest indie version of Unity3d. I have a Wii Remote with motion plus and Nunchuck and would like to know if will work with GlovePIE, PPJoy, and Unity3d indie. Do you have any scripts and demo for the same.
    Thanks in advance.
    MSL.
     
  13. kaz2057

    kaz2057

    Joined:
    Jan 18, 2011
    Posts:
    326
    he dropbox link is broken ... Ca you fix it please? I want to try your driver because I need to use my controller for presentations

    Thanks
     
  14. Cascho01

    Cascho01

    Joined:
    Mar 19, 2010
    Posts:
    1,347
    Right, please update the link!
     
  15. SpookyCat

    SpookyCat

    Joined:
    Jan 25, 2010
    Posts:
    3,770
    Could someone reupload this, would be interesting to play with.
     
  16. Euro3d

    Euro3d

    Joined:
    Oct 25, 2011
    Posts:
    11
    yeah please update the link, this would be very helpful!!
     
  17. DCrosby

    DCrosby

    Joined:
    Jan 13, 2013
    Posts:
    86
    So what seems to be happening is that the Values I get back from Unity, are positive on both axes, so you rotate up on X and you get .00004567 or whatever, and you rotate down and you get .00004567 when you're supposed to get -.00004567.

    Since it doesn't change it's impossible to detect positive or negative rotation values, if it was the other way around where you had positive or negative values that needed to go positive because you had +X and -X as two separate values/inputs that would work, since you'd be able to put a mathf.abs() around it...

    I also ported the whole thing to C#, so if anybody it looking for that let me know...
    I'm working now to get the API from 3DConnexion, and then hook into the dll, and then hopefully release some source, and a quick how to install the .DLL to get it to work.. on PC... on Mac I have no experience, but would imagine if the data handles for the .so file are the same it should be able to grab the data coming from the device.

    I'll try to update this, and somehow make it a permanent link, or something that can be re-constructed, by hand.
     
  18. shadybob56

    shadybob56

    Joined:
    Dec 2, 2022
    Posts:
    4
    Just getting into Unity myself recently, I see this thread is really old! Is there any updates to using a spaceball/navigator in the latest versions of Unity?