Some Bits: Nelson's log

PC gamepads: DirectInput vs XInput

I bought a crappy cheap game controller to use for a few weeks and ran into the total compatibility nightmare which is Windows game controllers.

Long story short, there’s two completely separate APIs. DirectInput and XInput. Old controllers (like my cheap PS3 knockoff) used DirectInput. Starting ~2005 Microsoft introduced XInput as a new API with better support for advanced controllers. It had drawbacks and some game controllers were slow to adopt it. Around 2011 Microsoft deprecated DirectInput, so everyone’s supposed to use XInput now. Despite that you can still buy new controllers that do DirectInput. Some controllers have a hardware switch to toggle modes.

What’s dumb is not all games still support DirectInput. (Looking at you, Dead Souls). Worse, Microsoft’s drivers don’t support some compatibility shims so a DirectInput device can be used via the XInput API. So you have to do something third party if you have an old DirectInput controller and want it to work with XInput. There’s three options I found:

x360ce is a thing that emulates an X360 controller and looks like an XInput driver but takes its input from DirectInput devices. I’m not sure it really is a driver, the hack includes its own XInput.dll you have to drop in to some games’ folders to fake it out. I didn’t try this, but it’s the usual old school gamer recommendation for solving this problem. It seems very flexible and hacker friendly. There’s newer binary builds on the GitHub page.

ScpToolkit is similar to x360ce, but emulates a Playstation controller. I did actually install this and found it didn’t work and uninstalling was spooky. I ended up using Windows’ rollback to remove it.

Steam Big Picture mode also includes an XInput emulator that seems to work well. I can’t find official docs for it and its confusing, but the Internet is full of badly written guides and videos on how to use it. This is what I ended up using. Setup is a bit fiddly; for awhile I was telling it to be “Generic” and it was sort of working but what I really wanted was “Playstation”. I’m still not clear if that means it’s emulating a Playstation controller, or if it is using this cheap controller I bought thinking it is a Playstation controller. Or both. Whatever, it seems to work.