Hi everyone,
I just bought the wireless SpaceMouse and I want to control it's behavior so on the same app it will sometimes act like a 2D mouse ("regular mouse")
and sometimes as a 3D mouse.
I saw that I can make it act like a 2D mouse with a config file (haven't tried it yet)
but how can I switch between states?
Thanks,
Tzafi
How to make the Wireless SpaceMouse act like a "regular" mouse
Moderator: Moderators
Re: How to make the Wireless SpaceMouse act like a "regular" mouse
You can do this, but the details are beyond the scope of this forum and our GUI. It requires editing cfg files.
A solution may depend on your application. Is it a 3D app that supports the 3D mouse?
Also, since you device has only 2 buttons, you are very limited in what you can do with it. Essentially you would have to dedicate a button for switching between 2D and 3D modes.
A solution may depend on your application. Is it a 3D app that supports the 3D mouse?
Also, since you device has only 2 buttons, you are very limited in what you can do with it. Essentially you would have to dedicate a button for switching between 2D and 3D modes.
Re: How to make the Wireless SpaceMouse act like a "regular" mouse
Thanks jwick,
My app is using VTK but I want to be able to use the SpaceMouse also like a 2D mouse.
I opened the config and saw this
<Button>
<Input>
<ActionID>HIDButton_2</ActionID>
</Input>
<Output>
<ActionID>Driver_Desktop_ToggleGrab</ActionID>
</Output>
</Button>
but I couldn't make it work...
Should it be in both config file?
Can I assigned it to an Axis and not a button?
Thanks!
My app is using VTK but I want to be able to use the SpaceMouse also like a 2D mouse.
I opened the config and saw this
<Button>
<Input>
<ActionID>HIDButton_2</ActionID>
</Input>
<Output>
<ActionID>Driver_Desktop_ToggleGrab</ActionID>
</Output>
</Button>
but I couldn't make it work...
Should it be in both config file?
Can I assigned it to an Axis and not a button?
Thanks!
Re: How to make the Wireless SpaceMouse act like a "regular" mouse
What cfg file did you put this in?
It has to be in the cfg file that is in use at the moment. If there are a bunch of cfg files being used (normally true), it would have to be in each. Or define it in the global cfg and it will be everywhere.
All Driver_Desktop_ToggleGrab does is change a single value in your %appdata%/desktop.xml file (<Grab>None----><Grab>Full-----><Grab>None...). You can do that with a vb/powershell/etc script and run that from your desktop. All you have to do is change the file. There's no magic here. You can even use notepad if you like. The driver will notice this and do the rest.
It can't be assigned to an axis in our driver, but you could do anything you want if you handled the axis yourself.
The best debugging approach is to turn on logging (3Dx systray icon) then see what the driver is doing when you click on different applications. It will switch from cfg file to cfg file (unless you have this focus grabbed in the desktop.xml file) and the log file will tell you what your buttons are being assigned to (you may have to change your LogLevel mask to see everything).
It has to be in the cfg file that is in use at the moment. If there are a bunch of cfg files being used (normally true), it would have to be in each. Or define it in the global cfg and it will be everywhere.
All Driver_Desktop_ToggleGrab does is change a single value in your %appdata%/desktop.xml file (<Grab>None----><Grab>Full-----><Grab>None...). You can do that with a vb/powershell/etc script and run that from your desktop. All you have to do is change the file. There's no magic here. You can even use notepad if you like. The driver will notice this and do the rest.
It can't be assigned to an axis in our driver, but you could do anything you want if you handled the axis yourself.
The best debugging approach is to turn on logging (3Dx systray icon) then see what the driver is doing when you click on different applications. It will switch from cfg file to cfg file (unless you have this focus grabbed in the desktop.xml file) and the log file will tell you what your buttons are being assigned to (you may have to change your LogLevel mask to see everything).
Re: How to make the Wireless SpaceMouse act like a "regular" mouse
Hi,
I added a function to my app that toggle between the (<Grab>None----><Grab>Hard-----><Grab>None...)
[change it on the Desktop_2DMouse.xml]
but it seems that every time I need to refresh my window (lose and gain focus) to get it work.
my guess is that the focus get the driver notice that something in the config has changed (but maybe I'm totally wrong here...)
Is there a way to rest the driver? to get it notice the change immediately?
(I saw SiSyncSendQuery and I thought maybe that is my direction)
Thanks!
I added a function to my app that toggle between the (<Grab>None----><Grab>Hard-----><Grab>None...)
[change it on the Desktop_2DMouse.xml]
but it seems that every time I need to refresh my window (lose and gain focus) to get it work.
my guess is that the focus get the driver notice that something in the config has changed (but maybe I'm totally wrong here...)
Is there a way to rest the driver? to get it notice the change immediately?
(I saw SiSyncSendQuery and I thought maybe that is my direction)
Thanks!