About programmable buttons, I made a tool to config a joystick/gamepad to use it within windows (and games).
http://necrodome.homeftp.net/Project...p_JoystickTool
You can also add functions by making a plugin dll...
About programmable buttons, I made a tool to config a joystick/gamepad to use it within windows (and games).
http://necrodome.homeftp.net/Project...p_JoystickTool
You can also add functions by making a plugin dll...
NecroSOFT - End of line -
Originally Posted by WILL
One question: Can a computer distiguish a gamepad, a steering wheel and a joystick, or does a computer always refers to them as game-input-devices. :?
Technically, joysticks, gamepads and steering wheels all have axises and a number of buttons. The Only difference is the shape.
So... do all "game input devices" need the same DX calls, or are there any differences??
Coders rule nr 1: Face ur bugz.. dont cage them with code, kill'em with ur cursor.
Well if you look at the two screenshots shown above it's pretty obvious that the configuration is fairly different. Son in that sense, yes, the mapping is the same, but different.
I'm not too sure about riving wheels & foot peddles though. I would assume that they are about the same. Which would lead me to my questions of how a game would manage a wheel device that turned all the way around. Or are they even able to do as much. Sorry, I've never used one myself.
I'd be interested in seeing a technical spec of a wheel though. Specifically how it's axis is oriented.
As far as libraries go... in the case of DirectInput(or any other API), it's really just reading states, which will probably be the easiest part of your game engine. The slightly trickier part is designing a layer on top of that to read information that the API gathered and turn it into something useful for your game. It's the same with SDL or any other API that will read the states of your game devices for you.
There are some description values in DirectX that drivers return. For example MOUSE, KEYBOARD, JOYSTICK, GAMEPAD, DRIVING, FLIGHT. There are loads of other values such as DUALPEDALS, REMOTE and LIGHTPEN so as long as the driver describes itself correctly, DirectX (and you) know what the controller actually is.
But they all return data in the same group of axis, POV and button data. How the data is actually stored there is up to the driver. Some gamepad drivers that return the DPad data as axis, some as POV and some as buttons!
I'm guessing for a wheel it returns 32767 when centered but behaves just like a thumbstick - the further it is moved the more that value alters. Full left would be 0 and full right would be 65535 with lots of values in between.
Bookmarks