Jump to content

About This File

TL;DR

The DirectInputFpxFix fixes an input related FPS drop/slowdown problem that occurs in FEAR, its expansions, Condemned: Criminal Origins and other games. It is easy to install and does not require manual disabling of HID devices.

 

Quick start guide:

  1. Extract the file dinput8.dll to the folder containing the executable of the game. For example: "C:\Program Files (x86)\Steam\steamapps\common\FEAR Ultimate Shooter Edition"
  2. Start the game like you would normally, for example directly through Steam or GOG Galaxy.

Features

The DirectInputFpsFix fixes a bug that causes the FPS to severely drop after a few minutes of play. This problem is probably most widely known in regards to the game FEAR and often occurs in conjunction with the usage of Logitech devices.

 

However, the problem also crops up in other games using the same engine, such as the FEAR expansions or Condemned: Criminal Origins and with non-Logitech hardware configurations. A similar problem has also been reported to occur in other titles, like Prototype.

 

Although this issue can often be fixed by disabling most/all HID-Devices in the device manager, it is bothersome to do so and lately some people reported that that solution does not even work at all anymore, especially on machines running Windows 10.

 

Instructions

Supported Games

The fix is agnostic towards the game that uses it and should therefore work with all versions of a supported game, including the Steam, GOG and retail versions.

  • Confirmed:
    • FEAR and its expansions
    • Condemned: Criminal Origins

    [*]Supposedly:

    • Prototype
    • Kane & Lynch: Dead Men

Feel free to provide feedback if the DLL works on other games as well.

 

Install

The fix does not make any permanent changes to the game or to Windows and can easily be removed.

  1. Extract the file dinput8.dll to the folder containing the executable of the game. For example: "C:\Program Files (x86)\Steam\steamapps\common\FEAR Ultimate Shooter Edition"*
  2. Start the game like you would normally, for example directly through Steam or GOG Galaxy.

*Note that for the FEAR expansions the fix also has to be installed into the corresponding sub-folder of the game

 

Uninstall

  1. Rename or remove the dinput8.dll from the folder of the game.

Known Issues

There are currently no known issues with the fix.

 

Additional Information

Antivirus Software

Since this mod consists of an executable DLL file that uses "hacking techniques" such as injection and hooking, it could be classified as malicious by antivirus software. In that case, it might be necessary to add an exception rule to the scanner.

 

If you lack the trust in random people on the internet -- and I would not blame you -- feel free to use a meta online virus scanner like VirusTotal to verify the file.

 

Loading Other Fixes/Mods/Injectors

To increase the compatibility with other mods or injectors that are using a wrapper DLL, this fix offers two methods for remote loading of additional files. Note that there might still be compatibility issues between the different fixes, mods or injectors that have nothing to do with the loading process.

 

File method:

 

The mod will load another dinput8.dll automatically if it has the name dinput8.dll. Just rename the DLL you want to load accordingly. Using this method will lead to an error if the renamed DLL is not itself a dinput8.dll.

 

Folder method:

 

The mod will also automatically load all DLLs regardless of their names in a dinput8 sub-directory. Just create a corresponding folder in the install directory of the mod. This is the only way to load multiple (conflicting) files.

 

How This Works

The fix is implemented using a common technique known as DLL hooking.

 

User input in games like FEAR can be realized via DirectInput, an API by Microsoft for interacting with HID-Devices. The library is ancient and should no longer be used today, because there are other ways to get mouse and keyboard input, especially for games.

 

The FPS drops happen because the thread that runs DirectInput massively slows down after a while (as can be seen in tools like ProcessExplorer).

 

If an application uses a library like DirectInput, it needs a so-called DLL (dynamic-link library) where the functionality of the library is stored. In many cases, especially for libraries provided by Microsoft, these DLLs usually reside in the Windows folder.

 

However, there is an order of how an application searches for the DLLs it needs. Since the DLL of the fix gets copied into the main folder of the application and has the same name of a DLL needed by the game (the one of DirectInput), it gets loaded instead of the one in the Windows folder.

 

This means that all calls to DirectInput go through the Hook-DLL and can either be directed to the original DLL in the Windows folder or changed as necessary. This also allows some insight in how exactly the library is used by the game.

 

It turned out that some games not only unnecessarily register all HID-devices, they also call several functions every frame that usually only should be called once during initialization. The latter seems to apply only to devices that are not keyboards or mice. This eventually leads to circumstances where a lot of time is spent opening and closing device connections.

 

The fix changes the DirectInput initialization in such a way that only keyboard and pointer devices get registered.

 

Contact And Support

If you like this mod and want to support the development or show your appreciation with a donation, you can find more information on my website. There you can also find out more about other mods that I have done and means to contact me if you have a question, want to provide feedback, bug reports and suggestions.


What's New in Version v1.0   See changelog

Released

  • Fixed a compatibility problem that prevented games to start on some systems
  • Added support for additional games
  • Updated the loading system to add support for remote loading of additional DLLs for increased compatibility with other mods and fixes (see Loading Other Fixes/Mods/Injectors)



User Feedback

Recommended Comments

Hey. Was feeling nostalgic, so I installed the old original FEAR tonight. Was getting 24fps. Searched, found this, followed it, and lo and behold, my screen refresh rate. Awesome! Thanks, it still works wonders.

Share this comment


Link to comment
Share on other sites

Maybe I'm doing something wrong, but this fix doesn't help in my case with the Prototype game. I still forced to disable part of HID-devices to get 60 FPS.

Share this comment


Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Found PCGamingWiki useful? Please consider making a Donation or visiting our Patreon.
  • Similar Content

    • By k4sh
      This Flawless Widescreen script is intended to fix in game FOV.
      First, download and install Flawless widescreen.
      Then, unzip this archive to the FWS directory.
      Run FWS.
      Run the game, and adjust the fix slider in FWS.
      Photo mode FOV will be overrided.
    • By k4sh
      This Flawless Widescreen script is intended to fix in game FOV for cinematics, puzzle ...
      First, download and install Flawless widescreen.
      Then, unzip this archive to the FWS directory.
      Run FWS.
      Run the game, load your savegame and adjust the fix slider in FWS.
      Be sure to set the FOV to vertical in game as this fixed has been made to work with it only.
      In game vertical FOV and FWS FOV slider are added.
    • By AlphaYellow
      This patch serves to add fixes to Prisoner of War, for now it adds Hor+ support.
      Instructions for setting a custom resolution:
      - Create a shortcut of Colditz.exe
      - Write "-res:x,y" in the shortcut's target field after "Colditz.exe": "-res:x,y" (without the quotes, for example: "Colditz.exe -res:1920,1080".
      More fixes will be added to this file in the future, since the game has a couple issues, like being locked to 32FPS and frequent slowdowns during gameplay, even with dgVoodoo.
      Credits go to: killer-m
      Password: pcgw
    • By kamiccolo
      SUWSF modified for Final Fantasy X/X-2 HD Remaster
      There are separate installs for both 2560x1080 and 3440x1440.
      Download the file specific to your monitor.
      All fixes are listed below.
      ---------------------------------------------------------------------------------------
      Render resolution fixed to custom aspect ratios for 43:18 and 64:27.
      Window aspect ratio control fixed for FFX.
      Window aspect ratio control fixed for FFX-2. (new custom pointer) 
      Main UI aspect ratio fixed for both FFX and FFX-2 for custom render resolution.
      Battle UI height and width fixed for FFX and FFX-2. (new custom pointers and compatibility fixes for increased render resolution)
      Controller Icons fixed for both FFX and FFX-2. (new custom pointers and compatibility fixes for increased render resolution)
      Garment aspect ratio fix for FFX-2. (new custom pointer and compatibility fixes for increased render resolution)
      Subtitles aspect ratio fix for both FFX and FFX-2. (new custom pointer and compatibility fixes for increased render resolution)
      Save fix for ff10. (new custom pointer and compatibility fixes for increased render resolution)
      Sphere Grid aspect ratio fix for FFX. (new custom pointers and compatibility fixes for increased render resolution)
      Outdoor aspect ratio fixed for all .exe's. (no longer breaks effects for both FFX and FFX-2)
      Indoor aspect ratio fixed for all .exe's to zoomed in 21x9 scrolling on 4x3 background.
      Max indoor bottom view for FFX. (fixed bottom view for best viewing)
      Custom indoor bottom view for FFX-2. (Optimized for best viewing)
      Map fix for FFX and FFX-2. (new custom pointers and compatibility fixes for increased render resolution)
      Large address aware added for extra stability for both FFX and FFX-2.
      ---------------------------------------------------------------------------------------

      Shout out to Phantom, Lyall, Lolhax and the rest of the team from WSGF for the support!
      https://github.com/phantomgamers/suwsf#module

      Cheers everyone and I hope you enjoy the 21x9 fix.
      Link to PCGW for new Launcher.
      https://www.pcgamingwiki.com/wiki/Final_Fantasy_X/X-2_HD_Remaster
      Visit WSGF for all your ultrawide needs!
      Link to WSGF.
      https://www.wsgf.org/
    • By Shadowspike74
      swaps the axis for buttons and stops the config application from crashing
       
      tested it and it works fine for me
      if needed test out if you need to incase of any faults
       
      drag and drop into crazy taxi 3 folder
  • Who's Online   1 Member, 0 Anonymous, 572 Guests (See full list)

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Member Statistics

    8,186
    Total Members
    3,870
    Most Online
    deckard
    Newest Member
    deckard
    Joined
×
×
  • Create New...