介绍
DX12 GL — Minecraft on Direct3D 12 (version 3.1)
Makes Minecraft render with DirectX 12 instead of OpenGL, without rewriting the game’s renderer: the mod replaces the OpenGL library LWJGL loads with its own, which tracks OpenGL’s state, translates the shaders and draws with Direct3D 12. That is why it stays compatible with other mods (tested with Embeddium, Oculus and Distant Horizons). It is a single .jar with everything included.
Requirements: Windows 10/11 64-bit · Minecraft Forge 1.20.1 · Java 17 · a Direct3D 12 capable GPU. If your PC does not support it or something fails at startup, the mod touches nothing and Minecraft keeps using plain OpenGL.
Results
Measured on an RTX 2060 (854×480 window). Your results may vary.
| Scene | OpenGL | DirectX 12 (this mod) |
|---|---|---|
| Vanilla, distance 12 | 185-191 FPS | 570-690 FPS |
| Vanilla, 1080p, distance 32 | ~60 FPS | 134-150 FPS |
| With Embeddium, distance 12 | ~274 FPS | ~1040 FPS |
The image is the same as with OpenGL. Much of the gain comes from applying OpenGL calls on a separate thread (it uses one more CPU core) and from drawing with D3D12.
What’s included
Renderer
- Direct3D 12 drawing with an asynchronous worker thread (can be turned off).
- Choose which GPU draws (useful on dual-GPU laptops), presentation cap, “frames ahead” (latency vs. smoothness), memory use (Low / Normal / High) and FPS in the window title.
- Save GPU (on by default): does not draw the frames the monitor will not show, nor anything while the window is minimized. The game keeps running the same; in vanilla with unlimited FPS GPU use drops from ~46% to ~29% (and to idle when minimized).
- If the driver resets or the GPU changes, the mod rebuilds everything by itself and the game keeps running.
- MSI Afterburner / RTSS overlays and screenshots (F2) work.
Upscaling and frames
- Resolution upscaling: spatial (built in), AMD FSR 3, Intel XeSS and NVIDIA DLSS (RTX only), with quality presets and sharpness.
- Frame generation (FSR 3 Frame Generation).
- Low latency: NVIDIA Reflex and AMD Anti-Lag 2 (the latter untested on a Radeon).
Shaders
- Shader compatibility (Oculus / Iris): translates the pack’s shaders (GLSL → HLSL) and compiles them in the background with a disk cache; a “Shader compilation” progress bar. Tested with Complementary Reimagined and Spooklementary; other packs may not work.
- Fast compile (DXC): compiles the pack’s shaders with Microsoft’s DXC compiler, in seconds instead of minutes, and recompiles them with FXC in the background (low priority) so the slightly GPU-faster version is used next time. Enabled by default.
- Compute shaders for mods that use them: for example the animated grass of Grassier Grass works with Oculus shaders.
- With shader packs DirectX 12 uses less GPU per frame than OpenGL in my tests (BSL 5.6 vs 6.3 ms; Spooklementary 4.1 vs 4.5 ms on an RTX 2060). Tested with Complementary Reimagined, Spooklementary and BSL.
Distant Horizons
- Works without shaders and with shader packs that support it (tested with Complementary Reimagined): distant terrain, water and DH objects.
In-game settings
- Options → Video Settings → “DirectX 12…” button, or the “DirectX 12” page of Embeddium’s menu. Hovering an option explains what it does and how it affects performance. English and Spanish text.
- Everything is stored in
dx12gl/config.properties(can also be edited by hand).
Installation
- Put the
.jarin your Forge 1.20.1 instance’smodsfolder. - Start the game once, close it and start it again. The first start only disables Forge’s early loading window; from the second start DirectX 12 is used (the window title shows
| DX12 NNN FPS). - Optional: Embeddium and/or Oculus. To use shader packs turn on “Shader compatibility” in the DirectX 12 settings and restart.
Known limitations
- Windows only, and Forge 1.20.1 only for now.
- The game believes it has OpenGL 3.3: OpenGL 4.x functions (DSA, indirect draws, persistent mapping) are not available. Of compute shaders only what Grassier Grass and similar mods need is implemented (no
imageLoad/imageStoreor atomics). - The first time a shader pack is used (or after updating the mod) its shaders are compiled: a few seconds with the “Shader compilation” bar, during which part of the world is not drawn.
- DLSS needs an NVIDIA RTX GPU; XeSS and FSR 3 work on any GPU. Frame generation adds almost one frame of latency and can leave small artifacts.
- The
.jaris about 160 MB because it carries the FSR, XeSS, DLSS and DXC libraries (they are copied todx12gl/automatically).
Licenses and credits
-
DX12 GL: LGPL-3.0-only. Author: thetiranix.
-
glslang (BSD-3-Clause and others) and SPIRV-Cross (Apache-2.0): linked inside the mod’s DLL.
-
AMD FidelityFX / FSR 3 (MIT license, © Advanced Micro Devices, Inc.), AMD Anti-Lag 2 (MIT).
-
Intel XeSS (Intel license, © Intel Corporation).
-
NVIDIA DLSS (NVIDIA RTX SDK license, © NVIDIA Corporation) and NVIDIA NVAPI / Reflex (MIT). DLSS is a trademark of NVIDIA.
-
Microsoft DirectX Shader Compiler v1.9.2609 (
dxcompiler.dll: LLVM/NCSA with exception;dxil.dll: Microsoft software license terms; source: https://github.com/microsoft/DirectXShaderCompiler). Included unmodified, in binary form only, and by using this mod you accept their terms for those two files (among others: use on Windows only). -
The full license texts are inside the
.jar, in thelicenses/folder. Windows libraries (d3d12.dll,dxgi.dll,d3dcompiler_47.dll) are not included: they are the system’s own. -
This mod is not an official product of, nor endorsed by, Minecraft, Mojang, Microsoft, NVIDIA, AMD or Intel. Minecraft is a trademark of Mojang AB.
MADE IT AND OPTIMIZED FOR https://www.curseforge.com/minecraft/modpacks/path-of-ascension modpack
It can contain some bugs.
常见问题
DX12mod 支持哪些 Minecraft 版本?
DX12mod 支持 Minecraft Java 版 1.20.1,可用的加载器:Forge。下载时注意选择和你游戏版本一致的文件。
DX12mod 怎么安装?
先用 PCL2 或 HMCL 启动器安装对应版本的 Forge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。
Thetiranix 的其他作品
查看全部 →Path of Ascension (BETA)
FORGE 1.20.1 ⚔️ The gods fell. Pick your race & class, earn divine favor, wield elemental weapons, slay dragons & Cataclysm bosses, survive brutal climates, climb the Aether & Twilight Forest. RPG · Bosses · Quests · 200+ mods 🔥(BETA)
Path of Ascension Core
Native content of the Path of Ascension modpack: races, classes, elemental damage, skill tree, tiered crafting tables and divine bosses.
评论
登录后评论和评分