Hello everyone.
I want to announce the first release of my free replacement driver and SDK for GNU/Linux. Free as in freedom of course (aka open source).
Both the new driver and the new library are made compatible with the 3dconnexion ones, and can be used as drop-in replacements. I've tested my driver with the Maya 8.0 plugin from 3dconnexion and it works perfectly.
The library in particular provides a totally new, more orthogonal API, as well as a magellan wrapper on top of it, so it can be used by existing applications without any code changes.
The project web page is at: http://spacenav.sourceforge.net/ (read the FAQ for more details), and you can download the initial release from the sourceforge download page: https://sourceforge.net/project/showfil ... _id=200169
Enjoy, any feedback, bug reports, patches, whatever will be appreciated :)
New free software (open source) driver and SDK project
Moderator: Moderators
Open source driver for 3dconnexion-SpaceNavigators
Hallo John,
really great work. I tested it under openSUSE 10.2 on kernel 2.6.18.8-0.1-bigsmp; under X everything works fine.
On a tty-console I did not yet manage to get it working,
spnav_open reports, that connect did not work. I will try
to isolate that problem.
If you could supply some information on the functions
spnav_x11_window and spnav_x11_event, it would be fine
(until now I don't need them and I don't think, I understood
what they are for).
Best greetings,
Christian
really great work. I tested it under openSUSE 10.2 on kernel 2.6.18.8-0.1-bigsmp; under X everything works fine.
On a tty-console I did not yet manage to get it working,
spnav_open reports, that connect did not work. I will try
to isolate that problem.
If you could supply some information on the functions
spnav_x11_window and spnav_x11_event, it would be fine
(until now I don't need them and I don't think, I understood
what they are for).
Best greetings,
Christian
Hello maurer.
Sorry for the late response, but it would be preferable if you contact me directly for such questions (nuclear@siggraph.org), as I don't monitor this forum regularly.
As for your questions:
This release of the driver/sdk (0.1) is an early one, in the sense that not everything is finished. In particular, the alternative non-X protocol does not get handled correctly by the daemon yet. So you have to use the standard X11 protocol (that also works with 3dconnexion's driver) for now (spnav_x11_open).
It's not difficult to make the alternative protocol handling work at this point, it's mostly done. So, if it is essential for what you are doing, let me know (email please), and I'll give it a priority.
spnav_x11_window() is the equivalent of MagellanSetWindow() of the original SDK. It sends a window ID to the daemon, which is to receive motion/button events. My daemon can work with many client apps at once, and many windows, so this just adds the window to the client window list. I'm not sure how the original daemon works (I was never able to make it run), but I suspect that it only works with one window and this function's purpose is to "replace" the window ID on the daemon.
spnav_x11_event() gets an XEvent pointer and a pointer to an spnav_event. If the current X event passed as the first argument is an event that comes from the driver (motion or button), it fills in the spnav_event, and returns SPNAV_EVENT_MOTION, or SPNAV_EVENT_BUTTON. Otherwise, it returns 0, which means that it's another kind of X event (not generated by the driver).
If you don't need to handle other X events you can just use spnav_wait_event() or spnav_poll_event() to block, or poll, for spacenav events, discarding any other X events.
spnav_x11_event, is similar to the MagellanInputEvent() and MagellanTranslateEvent(), which both seem to do the same thing with different event structures for some weird reason. In fact the Magellan wrapper provided by my replacement SDK, uses spnav_x11_event to implement both these functions.
Sorry for the late response, but it would be preferable if you contact me directly for such questions (nuclear@siggraph.org), as I don't monitor this forum regularly.
As for your questions:
This release of the driver/sdk (0.1) is an early one, in the sense that not everything is finished. In particular, the alternative non-X protocol does not get handled correctly by the daemon yet. So you have to use the standard X11 protocol (that also works with 3dconnexion's driver) for now (spnav_x11_open).
It's not difficult to make the alternative protocol handling work at this point, it's mostly done. So, if it is essential for what you are doing, let me know (email please), and I'll give it a priority.
spnav_x11_window() is the equivalent of MagellanSetWindow() of the original SDK. It sends a window ID to the daemon, which is to receive motion/button events. My daemon can work with many client apps at once, and many windows, so this just adds the window to the client window list. I'm not sure how the original daemon works (I was never able to make it run), but I suspect that it only works with one window and this function's purpose is to "replace" the window ID on the daemon.
spnav_x11_event() gets an XEvent pointer and a pointer to an spnav_event. If the current X event passed as the first argument is an event that comes from the driver (motion or button), it fills in the spnav_event, and returns SPNAV_EVENT_MOTION, or SPNAV_EVENT_BUTTON. Otherwise, it returns 0, which means that it's another kind of X event (not generated by the driver).
If you don't need to handle other X events you can just use spnav_wait_event() or spnav_poll_event() to block, or poll, for spacenav events, discarding any other X events.
spnav_x11_event, is similar to the MagellanInputEvent() and MagellanTranslateEvent(), which both seem to do the same thing with different event structures for some weird reason. In fact the Magellan wrapper provided by my replacement SDK, uses spnav_x11_event to implement both these functions.
These are the changes I've made to the driver:
* Separated and extended configuration handeling
* Added override config file for home directory
* Added led settings (on/off)
* Added driver level handeling of buttons
* Added capabilities change the inputed values
* Null either rotation, translation or both
* Invert either rotation, translation or both per axis
Diff (mostly contains whitespace alterations):
http://pastebin.com/f803729b
* Separated and extended configuration handeling
* Added override config file for home directory
* Added led settings (on/off)
* Added driver level handeling of buttons
* Added capabilities change the inputed values
* Null either rotation, translation or both
* Invert either rotation, translation or both per axis
Diff (mostly contains whitespace alterations):
http://pastebin.com/f803729b
Your driver solved my probs on gentoo
Hello!
You did a great work. The version 0.1 works for me on my gentoo machine. I thought I made a mistake buying my spacenavigator. But now I'm happy and can't live with out it.
Thomas Niemeier
You did a great work. The version 0.1 works for me on my gentoo machine. I thought I made a mistake buying my spacenavigator. But now I'm happy and can't live with out it.
Thomas Niemeier