Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (525)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (592)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  diff JavaJoystick jinput  (Read 6340 times)
0 Members and 1 Guest are viewing this topic.
Offline Conzar

Junior Devvie




There is nothing common about common sense


« Posted 2003-07-14 19:17:40 »

So what are the differences of JavaJoystick and jinput.
It appears sourceforge's site is not responding (as of 5:21pm today) so I wasn't able to find anything on JavaJoystick.

What is jinput and who is developing it?  Is there a web page?

Thanks

Ubuntu
Offline endolf

JGO Coder


Medals: 7
Exp: 15 years


Current project release date: sometime in 3003


« Reply #1 - Posted 2003-07-14 19:51:33 »

Hi
 java joystick is joystick only, jinput is joystick, mouse and keyboard, with gamers in mind. Sun have done the standard and I beleive they did the windows version, both the mac OSx and linux versions are being developed by others as part of the community project.

HTH

Endolf

Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #2 - Posted 2003-07-14 20:36:06 »

JInput would presumably expand to cover flight yokes, steering wheels & foot pedals and all the other "fancy" controllers too.
I don't know anything about JavaJoystick.. does it support force feedback etc?  JInput is designed to.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Jeff

JGO Coder




Got any cats?


« Reply #3 - Posted 2003-07-14 21:02:51 »

(edited for typos, and no swp, I wasn't on my mac Tongue)

Its been crazy for me, I apologize. We are getting our house ready for sale and trying to get packed up and moved out by the middle of next week.

As the project manager for Jinput let me define it for you real fast:

Its is a cross-platform API for the discovery and polling of input devices including (but not limited to) keyboard, mouse, joysticks, wheels, game-pads, etc.  It provides a unified  method of discovering, understanding, and  polling all these devices.

The closest analagous system is MSFT's Win32 specific DirectInput but JInput is not platform specific.  

JInput has two parts to it.  The "top part" where the API is defined is pure Java.  The "bottom part" consists of one or more platform specific plug-ins.  To port JInput to a new platform, you write a new plug-in.

JInput was designed by a Sun and a Sony Computer Entertainment employee working together as a sub-committee in JSR134.  Since that time we have completed a reference implementation that includes a Win32 plugin and released it all as an open source project at http://jinput.dev.java.net

Hope that helps.  Don't ask me about the other source-forge project as I know nada about it.

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #4 - Posted 2003-07-15 00:46:27 »

Jeff, you must not have been at your Mac.. or you turned off the spell checking Smiley

Is the either of the Sun or Sony employees participating on these forums?

Offline Jeff

JGO Coder




Got any cats?


« Reply #5 - Posted 2003-07-15 01:28:53 »

Unless you have heard something I haven't about my employment status then there are definitely Sun employees participating (me, Chris when hes back, Doug, Dan, Athomas, Ken, etc...)

If there's anyone from Sony then they haven't announced themselves.


Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline tortoise

Junior Devvie




<3 Shmups


« Reply #6 - Posted 2003-07-15 01:35:40 »

JavaJoystick is very simple and is modelled after the AWT event model for the most part (although it doesn't use any actual "event" objects).

You implement the JoysticKListener interface:

public void joystickButtonChanged( Joystick j );
public void joystickAxisChanged( Joystick j );

And then the Joystick object is just a simple little object to find out what was changed.

You can also poll the joystick but it's still the exact same underneath, just slightly different at the interface level.

I am currently using JavaJoystick in my game and I have no complaints. It's simple, but it does what I need and has no bugs as far as I can tell.
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #7 - Posted 2003-07-15 01:56:38 »

I meant of the two people on the team that developed the code as part of JSR134.

I figured you would have said if it was you and some dude from Sony, so that would mean it is a Sun person other than you that developed the JInput stuff that is sitting in CVS.   Which one of you was it, or is that person on to other things now?

Offline Herkules

Senior Devvie




Friendly fire isn't friendly!


« Reply #8 - Posted 2003-07-15 04:35:47 »

Nobody still considers JXInput?   Cry  Cry


HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline Conzar

Junior Devvie




There is nothing common about common sense


« Reply #9 - Posted 2003-07-15 12:12:11 »

Well, Sourceforge is back up and I checked out JavaJoystick.  I tried their test program with my Gravis Gamepad (USB) under Linux and it worked great.

I've looked at the code (both Java and C++) and its pretty easy to understand.  

Maybe JavaJoystick and JInput can hookup or something???  

Ubuntu
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline tortoise

Junior Devvie




<3 Shmups


« Reply #10 - Posted 2003-07-15 12:46:57 »

If I understand correctly jinput's pretty much got the joystick end of things down pat. JavaJoystick is still limited to Linux and Windows as well, a sizable shortcoming IMO (I will probably ditch JJ as soon as I start looking into supporting OSX). It's probably more a case of JavaJoystick is just becoming obsolete.
Offline kevglass

« JGO Spiffy Duke »


Medals: 208
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #11 - Posted 2003-07-15 12:50:25 »

I'm still surprised by this complete acceptance of SUN trampling all over an open-source homested thats been settled so long..

We've had a "sorta" explanation in the JOGL area, what about in the JInput area? JavaJoystick and JXInput do some pretty similar things to JInput.

Kev

Offline Conzar

Junior Devvie




There is nothing common about common sense


« Reply #12 - Posted 2003-07-15 13:07:59 »

As for JXInput - thats windows only right?

I think, since JavaJoystick already has something for Linux and JInput doesn't have anything for linux - then JavaJoystick might be able to be incorperated into JInput.

There is a differnce between something becoming obsolete and something merged/combined/extended.  I was thinking that JJ could be used in the JInput's Linux development.  

But if JInput feels that can do the Linux part without JJ, then more power to them.

Ubuntu
Offline tortoise

Junior Devvie




<3 Shmups


« Reply #13 - Posted 2003-07-15 13:11:27 »

My bad, a post somewhere else in this forum had me thinking they had Linux joysticks covered. Maybe not.

I have nothing against JJ, and like I said I'm currently using it. But it seems kinda silly to adopt two joystick libraries, one for linux/win and the other for OSX, if I can find one that does all three.
Offline endolf

JGO Coder


Medals: 7
Exp: 15 years


Current project release date: sometime in 3003


« Reply #14 - Posted 2003-07-15 13:17:58 »

Hi
 under linux the joystick is the least of my worries. It has an easy to use, well defined interface. Mouse and keyboard on the other hand (which are part of jinput, but non of the others) are prooving to be a right pain in the butt Smiley

Cheers

Endolf

Offline Herkules

Senior Devvie




Friendly fire isn't friendly!


« Reply #15 - Posted 2003-07-15 13:33:10 »

Quote
As for JXInput - thats windows only right?


Nope. Only the pure joystick driver is currently available for Windows only. JXInput as an input solution with virtual/mixed axes/buttons/directionals or the eventing system is cross-platform.
There are not too many joysticks connected to Linux/Mac-boxes out there on the consumers desk?

Yes, jinput is quite similar to JXInput and I am a little bit annoyed that Sun did it again without consulting anybody else....

HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline kevglass

« JGO Spiffy Duke »


Medals: 208
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #16 - Posted 2003-07-15 14:23:40 »

Even if they arn't cross platforms, generally in the open source community it would have been more apprioriate to build on the existing code. So, SUN could happily have come along and helped to add full support to JXInput and/or JavaJoystick.. and even expanded them to handle keyboard/mouse input.

On another note, I can understand why SUN felt JOGL was too big to just add to the Java standard. However, in the case of JInput keyboard/mouse input, wouldn't it have been easier to just open up the AWT event system a bit?

Kev

Offline Conzar

Junior Devvie




There is nothing common about common sense


« Reply #17 - Posted 2003-07-15 22:43:30 »

So what is bad about the current AWT event handling of mice and keyboard?

Also - w/ JInput, I've looked through the code and man, there needs to be some documentation on how the thing works especially if JInput wants 3d parties to add modulas.  Some design docs on the module interface is much needed.  JavaDoc doesn't cut it when extending/implementing existing software.

Ubuntu
Offline tortoise

Junior Devvie




<3 Shmups


« Reply #18 - Posted 2003-07-16 00:34:30 »

Quote
So what is bad about the current AWT event handling of mice and keyboard?


AWT keyboard input is downright broken in Linux. It's not Sun's fault, it's the way X does it, and I wouldn't be surprised if it's equally broken in other Unices. It suffices for typical applications, but not for games.

It'd also be nice to do input in the same thread as logic.

But as it stands AWT input in Windows is decent enough.
Offline Conzar

Junior Devvie




There is nothing common about common sense


« Reply #19 - Posted 2003-07-16 18:56:34 »

Umm, I use linux and have been using linux for several years.  I haven't noticed anything wrong or funky w/ the keyboard nor mouse event handeling

Can you give specifics, where its "broken"?  

Ubuntu
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #20 - Posted 2003-07-16 20:33:19 »

It gives bogus keyReleased events when you hold down a key.  There is basically no clean way to know that a key is being held as opposed to being tapped repeatedly.

Offline Jeff

JGO Coder




Got any cats?


« Reply #21 - Posted 2003-07-22 16:15:19 »

Been VERY busy with a huge move guys, sorry, will be better involved again next week.

As to the rationale:

(1) For the record, Sun didnt invent JInput.  Its was develoepd by the JSR134 expert group which included folks from many different companeis including Sun, Sony, BLAM!, EasyStreet Games, and some other odds and ends.

(2) The goals on JInput were to have a generic input model that was extensible across all reasonably predictable input devices, gave polled IO, was cross platform, did not require AWT to be loaded, and did controller discovery.

At the time NONE of those present in the expert group knew of an existing solution that did this.  Given the hundreds of thousands if not tens of millions of OpenSource projects that exist on the net today, I don't think you can fault them too badly for not being aware of every possible one that might
pertain.

Of what we in the EG DID know of, generally there were one of three problems:  (1) Not cross platform (straight DX bindings), (2) No support for generic input devices (Joystick, or in some cases Joystick and mouse), (3) No discovery.

As for existing OpenSource input projects I love hearing about them as my feeling is any good ideas and/or code leg-ups we can get from them the better Smiley

I really feel a need to stress that these aren't "Sun's APIs" here at java.net.  If they were, we wouldn't be releasing them this way.  These are intended to be YOUR APIs (the java.net community.)  

If the community as a whole decides that they'yd rather throw away the work we've done to try to assist and jumpt-start this and move to something else, thats fine.  Thats one of the reasons why we have an open community of projects.  Don't like ours? Start your own!

JK


Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline Jeff

JGO Coder




Got any cats?


« Reply #22 - Posted 2003-07-22 16:18:22 »

P.S. As for a porting guide,  I recognize the need. I'm up to my eyebrows in alligators right now though.  If someone else wanted to do it I'd be happy to support as I could through email.  Otherwise its on my list to do WHEN my schedule clears a bit.


Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

toopeicgaming1999 (67 views)
2014-11-26 15:22:04

toopeicgaming1999 (58 views)
2014-11-26 15:20:36

toopeicgaming1999 (12 views)
2014-11-26 15:20:08

SHC (24 views)
2014-11-25 12:00:59

SHC (24 views)
2014-11-25 11:53:45

Norakomi (29 views)
2014-11-25 11:26:43

Gibbo3771 (24 views)
2014-11-24 19:59:16

trollwarrior1 (37 views)
2014-11-22 12:13:56

xFryIx (76 views)
2014-11-13 12:34:49

digdugdiggy (53 views)
2014-11-12 21:11:50
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!