GithubHelp home page GithubHelp logo

destroyerdarkness / dinput8wrapper Goto Github PK

View Code? Open in Web Editor NEW

This project forked from geeky/dinput8wrapper

0.0 0.0 0.0 72 KB

This is a DirectInput 8 (dinput8.dll) Wrapper, which internally uses Raw-Input instead of DirectInput

License: MIT License

C++ 74.67% C 25.33%

dinput8wrapper's Introduction

dinput8wrapper

This is a DirectInput 8 (dinput8.dll) Wrapper, which internally uses Raw-Input instead of DirectInput.

Initially created to have a different way to fix the frame stuttering caused by regular EnumDevices()-calls in "Kane & Lynch: Dead Men" Other workarounds are listed here: https://www.pcgamingwiki.com/wiki/Kane_%26_Lynch:_Dead_Men#Stuttering

Whats the issue?

Dependending on the number and type of physical/virtual "USB HID"-devices on the system the EnumDevices()-call can take a few ms to return. Games sometimes call this function regularly in the main thread to check if a new gamepad is attached/detached, which will then cause regular frame stuttering due to the pauses caused by EnumDevices(). This wrapper returns a fixed keyboard-device and a fixed mouse-device in EnumDevices() and does not do any real device enumeration.

Current state:

  • Only supports Keyboard and Mouse (gamepad-support in progress)
  • Does only implement a small subset of the DirectInput8-Interfaces (may not work with all games using DirectInput8)
  • 32-bit only (Is there any DirectInput8-game that requires x64?)

How to use / Installation

  • Copy the dinput8.dll (see https://github.com/geeky/dinput8wrapper/releases) to the folder where your game has its main executable
  • Hope that the game will load it instead of the original dinput8.dll from the windows-system32-folder
    (Its a bad idea to override the original dinput8.dll!)

Compile yourself

dinput8wrapper's People

Contributors

geeky avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.