promotional bannermobile promotional banner
premium banner
Fixes the DPI of Minecraft

Description

Description:

DPI-Fix Mod fixes the High DPI Scaling Awareness of Minecraft. Simplified It fixes the blurriness of minecraft when the scaling of the monitor is above 100%. It also increases minecraft's process priority to high when enabled. This mod only fixes dpi for Windows right now as I couldn't seem to find any documentation on how to prevent dpi scaling on macOs or linux without editing the LWJGL natives window creation flags. Help is wanted if your a c++ dev and know the solution.

Imagine this; you sit down after a long day of work fire up multimc or curseforge launcher to play your minecraft 1.6.4 or even 1.7.10 modpack and........ after 10 minuets of waiting for it to load it's blurry. You have to adjust your dpi back to 100% and then relaunch both multimc and minecraft and make everything way too tiny just for minecraft to be happy. 

Sounds familiar? Don't pull out your hair anymore this mod fixes it. It works by setting the game to be dpi aware before Minecraft's Window even becomes visible.

How to install the Mod MC 1.6 or Higher:

  • Drag and Drop into the mods folder

How to Install for MC 1.5 - 1.5.2 with Forge:

  • Drag and drop into the coremods folder
  • Add JVM Argument -javaagent:coremods/[1.5-1.12.2]HighDPI-Fix-1.5.4.jar

How to Install for Any Minecraft Version For Any Mod Loader or Vanilla Without the CoreMod Functionality

  • Create a Folder called "agents" under your ".minecraft" folder
  • Drag and drop into agents
  • Add JVM Argument -javaagent:agents/[1.5-1.12.2]HighDPI-Fix-1.5.4.jar
  • Add JVM Argument -Dgamemodelib.cfg=true

Advanced Users For Any Java Application:

  • Create a Folder called "agents" under the program's working directory for minecraft ".minecraft" for example
  • Drag and drop into agents
  • Add JVM Argument -javaagent:agents/[1.5-1.12.2]HighDPI-Fix-1.5.4.jar
  • Below Add which Optional Arguments you want DPI-Fix Agent(GamemodeLib) to do
  • Optional JVM Argument -Dgamemodelib.dpi=true
  • Optional JVM Argument -Dgamemodelib.high=true
  • Optional JVM Argument -Dgamemodelib.niceness.mac=-5
  • Optional JVM Argument -Dgamemodelib.niceness.linux=-5
  • Example -javaagent:agents/[1.5-1.12.2]HighDPI-Fix-1.5.4.jar -Dgamemodelib.dpi=true -Dgamemodelib.high=true -Dgamemodelib.niceness.mac=-10 -Dgamemodelib.niceness.linux=-5

Features

  • Fix DPI
  • Set Process Priority of Minecraft to High (configurable) +10FPS
  • Fix MC-68754 (Exiting Fullscreen Disables windows Maximize Button) 
  • Fix MC-111419 (Fullscreen not saving)
  • Fix MC-160054 (ALT+TAB Minimizes Game)
  • Fix MC 1.6x Maximize while World is Loading Results in improper resizing
  • Fixes LaunchClassLoader RAM leak caused from minecraft's launchwrapper library. Supports fixes from launch wrapper 1.3 - 1.12. Supports Overriding Foam Fix's Broken Fix to ensure no memory leak happens (Dpi-fix 1.5.0+)
  • Fix Optifine 1.7.10 or higher on macOS for modern java 8
  • Fix WhiteScreen Flashes on 1.6x GuiMainMenu
  • Fix Technic Launcher with De-AWT mods
  • Fix Mod logos 1.5 - 1.6.4
  • Fix Mod logo memory leak bug Forge 1.6x that would eventually in a short time cause java to run out of memory and crash

Features Java Agent Only Mode

  • Fix Dpi
  • Set Process Prioirty to High
  • LaunchClassLoader Memory Leak Fix that is compatible with FoamFix

Supported Minecraft Versions

  • 1.5
  • 1.5.1
  • 1.5.2
  • 1.6.1
  • 1.6.2
  • 1.6.3
  • 1.6.4
  • 1.7.2
  • 1.7.10
  • 1.8
  • 1.8.9
  • 1.10.2
  • 1.11.2
  • 1.12.2

Supported Operating Systems

  • Windows 7 (x86 and x64)
  • Windows 8.1 (x86, x64 and arm64)
  • Windows 10 (x86, x64 and arm64)
  • Windows 11 (x86, x64 and arm64)

How to get High Process Priority for MacOS & Linux Dpi-Fix 1.4.2+:

  • For macOS download and install https://github.com/jredfox/change_niceness/releases
  • For linux download and install https://github.com/jredfox/renicer/releases
  • Reboot Minecraft and you should see high priority. Verify High Priority using terminal "ps -o ni -p <PID>" where the pid is found in activity monitor or system monitor. It should say NI -5
  • You can configure the niceness value between -1 and -20 for high priority. -5 is default high and very high is -10 through -20. Be aware values < -5 may make the mouse gpu and minecraft process out of sync just like windows realtime process priority. This is why it's set to -5 so we don't cause any problems while still providing the best latency and increased FPS. 

FAQ
______________
Q: Is The Installation Process the same for all minecraft versions
A: Yes except legacy versions

Q: Will this work with java 9 or higher
A: No as Minecraft Itself Doesn't work with java 9 or higher until minecraft 1.13+

Q: Will this work if I change the DPI while the game is Running
A: On Windows 8.1 or higher yes but untested on windows 7 if you have to restart or not since we ignore the dpi scaling factor

Q: Is this mod a virus why are there DLL files
A: it's C++ code and all it does is set the dpi awareness and set the process priority. The Source is found under src-cpp

Q: Why Do I have install change_niceness(mac) or renicer(linux) to get High Process Priority?
 A: The renice command won't set process priority to high without admin every time (niceness -5). So we make a workaround for silly security. Windows has proved for a long time now HIGH process priority is safe to set without admin. change_niceness is a over simplified copy of renice that works for mac snow leopard or higher as renice on silicon doesn't work outside /usr/bin/renice. renicer is a copy of renice just made so you don't need admin to change process priority.

Q: Will fixing dpi work on macOS:
A: Yes. macOS works differently for DPI Scaling. You can't change the scaling without also changing the virtual resolution of the display. so no fix is needed

Q: Will this work on linux
A: No. I couldn't find any documentation on how to get the application to be DPI aware without editing LWJGL natives as the only thing I found required a window creation flag inside the parameters. I also found out that minecraft 1.13+ using LWJGL 3 when it tries to set the fullscreen resolution it incorrectly gets it resulting in rendering way higher then the actual resolution of the screen. So fixing it even if possible would probably cause a similar result thus HELP IS WANTED ON SUPPORTING LINUX DPI SCALING. the scaling is very buggy on linux anyways I recommend turning it off always and just change the resolution of the screen instead or make text / icons bigger if it's too tiny