Anything further on force feedback? I’d be happy to make a proposal if nothing has been done recently.
Rumbler support is in for linux and windows (not sure about OSX).
As yet I’ve not heard much noise about people wanting to extend this to more generic force feedback support.
HTH
Endolf
* Herko_ter_Horst makes noise
I would love to have “real” force feedback in Java.
I have looked into doing force feedback in the past, and as far as I’ve been able to determine, Immersion pretty much owns the tactile feedback marketplace. Most if not of the force feedback gaming products I know (mostly Logitech joysticks and wheels) use Immersion boards. Immersion offers several (commercial) SDKs, including a Java one which provides a JNI binding to a native (ActiveX) component, which (sadly) seems aimed at mouse feedback effects for applets.
As far as I’ve been able to determine, the protocol is rather simple, but may be illegal to reverse engineer :-\
Hi
Any force feedback we did would most likely be a wrapper around direct input on a windows environment, and the event nodes on linux. No idea how to do it under OSX, but thats Elias problem (even if he doesn’t know it yet ;p).
I guess the first step would be to try and determine how we extend the coreAPI of JInput to cover the possibilities of full force feedback.
I’ll take a look and see what I think would be a good starting point for the discussion
Endolf
Looking at the linux API for force feed back and at direct input, it looks as though there are a few classes of effect.
- Constant force
- Ramped force
- Spring
- Friction
- Damper
- Periodic - waveforms
- Rumble
- Inertia
The properties of each differ, with some overlap, so I’m going to suggest that we would just have one class per effect type.
Supported wave forms are
- Square
- Triangle
- Sine
- Saw up
- Saw down
- Custom
Custom looks scary as this is ‘some potentially device specific’ data, and I think passing that around as byte[]'s or what ever is a bad idea, feel free to object to that view if you need this.
In both directx and linux, there is an effect class, that contains some generic information, and then a reference to one of the more specific data classes. We could either move that common information in to the effect descriptor classes, or have an effect class, that holds a reference to an effect descriptor class. The issue there is how we pass the information to the plugin/native layer. at some point we need to either then do lots of instanceof checks, or the effect descriptor needs to know how to deal with the plugin specifics. Both of which suck as solutions.
I’m begining to ramble as it’s getting late here, so i’ll leave it at that for now, and see what comments come out. Then ramble some more tomorrow
Endolf
I’m throwing this out for contemplation because there is now some serious movement at the higher levels of some communities for a generalised haptics description capability. SenseGraphics H3D API has a pretty huge support amongst the haptics-using industry and there’s several working groups and open source projects (SOFA being the biggest of those) that are starting to work towards some sort of commonisation of haptics.
An additional feeder to that is the Medical working group of the Web3D consortium is starting working on specifying haptics capabilities as part of the X3D spec.
It would be nice is JInput had more than just “force feedback” capabilities and was capable of more general haptics rendering.
There is always one that has to go and make things complicated ;p
Ok, I don’t propose for now that we implement anything complicated, but lets see if we can come up with an API enhancement that will allow us to implement force feedback for now, but allow enough scope in the API that should anyone desire too, they can create specific device plugins to handle full haptics capable devices
JInput is primarily a games technology, so I’d like to get that aspect working, but I’m certainly open to the idea of it being used for more.
Endolf
Ok, I’ve had a hunt around. There does not seem to be a generic haptic interface at the moment. I’ve had a look at the programmers guide for [rul=http://www.sensable.com/products-haptic-devices.htm]Open Haptics[/url] which dispite the name, is commercial software (event the educational version relies upon you sending them money). It looks like at it’s lowest level, it’s just a bunch of forces, maybe even reusing some of the force feedback forces (constant for example).
With out a few thousand USD I’m not going to find out though :(.
I suggest for now we just proceed with the idea of following the directx/linux input methods. It looks like Immersion developed the OSX APIs, as support is provided by them. They already have a Java SDK, which might prove handy. I’ve contacted them for further information.
Endolf