Archived

This topic is now archived and is closed to further replies.

nitzan

multiple usb gamepads...

Recommended Posts

How do I initialize and use mutliple gamepads with directx ? I glanced at the SDK but the joystick example only initalized one gamepad, and I had difficulty deciphering the other examples. Thanks, Nitzan

Share this post


Link to post
Share on other sites
Enumerate all DI devices, determine if they are gamepads by looking at the dwDevType member of the DIDEVICEINSTANCE structure you have from the enumeration callback parameter.
Then, create the devices as needed, using the GUIDs also available from that structure.
It is good practice to make a list of the enumeration results, so that the player/s can choose which devices to use - same as with display, sound and network devices.

-Nik

Share this post


Link to post
Share on other sites