DLSSTweaks
DLSSTweaks copied to clipboard
Ultra Quality setting (test build available)
E: test build can be found below at https://github.com/emoose/DLSSTweaks/issues/22#issuecomment-1443624026
In this recent reddit thread some people seem to be reporting games that allow selecting Ultra Quality: https://www.reddit.com/r/nvidia/comments/11763es/do_we_need_more_dlss_options/
It's a little strange to me though since when I tried forcing the PerfQualityValue
parameter to UltraQuality to find what DLSS would set the resolution to, it always returned 0x0 resolution for me - maybe it does get enabled for certain appIds passed to DLSS though?
Some mentioned that it only seemed to show up after updating to DLSS3.1 (eg. this thread, where they also posted a screenshot of Ultra Quality showing an option in game), we know that 3.1 can configure presets per-appId, so maybe ultra quality was also now enabled for some apps too.
If anyone owns one of the games mentioned there (Hogwarts Legacy, RDR2?) and can test with the dev DLSS 3.1 DLL to see what "Ultra Quality" shows as on the overlay it'd be appreciated.
E: oh it's possible that DLSSTweaks itself might be the cause, if the game is detecting the available quality levels by asking DLSS for the resolution of each of them, DLSS by itself would have returned 0x0, but DLSSTweaks with DLSSQualityLevels enabled would pass 77% of screen res: https://github.com/emoose/DLSSTweaks/blob/5977cee001abd5b80ede7c2bc79992e61bf23b33/src/DllMain.cpp#L46
When I removed UltraQuality I figured it wasn't a big deal to leave that there in case future games do include it (and also left in the code to read value from INI too, just removed it from the INI itself), but if there are current games that this helps expose the setting in maybe it could be worth re-adding back to INI, with a note or something next to it.
Here are my results for Red Dead Redemption 2
DLSS 3.1.1 (downloaded from here: https://www.techpowerup.com/download/nvidia-dlss-dll/) doesn't seem to expose an Ultra Quality mode in the UI when using it with Red Dead Redemption 2 in DX12 or Vulkan mode.
I then tested DLSS 3.1.1 with Red Dead Redemption 2, but with OverrideAppId = true
with DLSS tweak. Same results as before for both DX12 and Vulkan.
I then tested 3.1.1 dev (from here: https://github.com/NVIDIA/DLSS) with Red Dead Redemption 2. And I got the exact same results as before in DX12 and Vulkan, with and without OverrideAppId = true
.
Later on in the thread you linked too, the user claims Cyberpunk 2077 will show an Ultra Quality mode if you swap out the DLL and turn on OverrideAppId = true
. I couldn't reproduce this either.
Extra notes: GPU: RTX 4090 GPU driver: 528.49 Studio Driver OS: Windows 11
@Treemcgee324 could you check if setting [DLSSQualityLevels] Enable = true
might let it show in RDR? It's possible the ratio DLSSTweaks applies for UltraQuality by default when that's enabled is what makes it show (updated OP with more info)
in red dead it shows Ultra Quality but crash after loading,witcher 3 wont even show
I don't have it RDR2 installed anymore so I can't recheck. But when I selected ultra, the overlay just disappeared. I think it was running native with TAA, but I'm not 100% sure.
Thanks for the comment @emoose
When I ran my initial set of tests with DLSS tweak, I used DLSS Tweak 0.123.8 (the one that released a week ago). So that probably had an impact on the results.
Now after upgrading to DLSS tweak 0.123.10beta3 (from here: https://github.com/emoose/DLSSTweaks/issues/2#issuecomment-1436107437) these are my observations:
Note: The Vulkan backend was used for testing with Red Dead Redemption 2.
In Red Dead Redemption 2, turning on [DLSSQualityLevels] Enable = true
(I also had OverrideAppId = true
enabled just in case), this results in DLSS Ultra Quality showing up in the UI. This is even with DLSS 2.2.10 (what's included with the game). However, the game crashes as soon as 3D rendering starts and DLSS Ultra Quality mode is enabled.
Updating to DLSS 3.1.1 dev doesn't change anything. The game continues to crash.
If I add UltraQuality = 0.8
in the [DLSSQualityLevels]
section of the ini file for DLSS tweak (just to override it), and use DLSS 3.1.1, there is still no changes. The game still crashes if Ultra Quality is used. (I might of done this step wrong)
I then decided to test some other games. All games were tested with [DLSSQualityLevels] Enable = true
and OverrideAppId = true
with DLSS 3.1.1 dev. And I verified that DLSS tweak was working in each game.
A Plague Tale Requiem: Ultra Quality is exposed in the UI, but the rendering is broken (DLSS is stuck cycling through the last few frames from before changing the setting to ultra quality mode). I say DLSS is stuck because all the stuff not controlled by DLSS works just fine (UI, subtitles, audio, game inputs, playing the game). It's just the render of the 3D world that is stuck, and that's controlled by DLSS. As such I couldn't get any useful information for you. Maybe DLSS is requesting an internal resolution of 0x0 as suggested before? Or something else is broken?
Cyberpunk 2077: No Ultra Quality UI
Marvels Spider Man Miles Morales: No Ultra Quality UI
Portal with RTX: No Ultra Quality UI in both the normal UI and the developer settings.
The Witcher 3: No Ultra Quality UI
Ah thanks for the info all, sounds like it probably is DLSSTweaks causing it to show up, it's too bad choosing the option causes issues right now since having another DLSS level available to tweak would have been nice.
My guess is that even though we're returning a valid resolution for UQ to the game (making the game think that the level is valid), DLSS was still asked to use UQ which it doesn't want to, stopping it from rendering properly.
Would maybe be possible to work around by just overriding what DLSS gets told to use if UQ is chosen, but not totally sure how that'll work out, will need to get hold of a game that shows the option and test out some things... for now I think I'll probably just set our UltraQuality default to 0, so we'd return pretty much same as DLSS itself would.
If it is actually the quality level causing DLSS to stop rendering properly that's kinda interesting though, didn't think DLSS cared about quality level other than using it to tell game the scaled res to use. Could possibly mean DLSS is making other decisions/changes based on each quality level too, so eg. if you had UltraPerf & Quality both at 80%, maybe they wouldn't actually result in the same image, no idea how true that is yet though.
Think I might have Ultra Quality working now, just overriding what we tell DLSS the preset is (changing it to MaxQuality), while still using the UltraQuality ratio that user set, seems to let it work in RDR2 at least.
Here's a test build if anyone wants to try: dlsstweaks-0.123.12beta1.zip
The comments in DLSSQualityLevels
section should mostly explain how it works, pretty much just need to enable DLSSQualityLevels
& uncomment the UltraQuality
line to try it out.
Not every game will actually show the Ultra Quality option when set though, so far I only know of RDR2 & Hogwarts Legacy, and I've only tested it with RDR2 myself. If anyone finds any other games it works in please let me know!
(there's a small chance enabling UQ might help with the Hogwarts Legacy issues some people reported with .10 & .11 too, we know the game does try querying UQ and shows it as an option at least, guessing that could have something to do with the startup crashing... not really sure though, if anyone tries it let me know how it goes)
0.123.12beta3 release: dlsstweaks-0.123.12beta3.zip
(older 0.123.12beta2 release: https://github.com/emoose/DLSSTweaks/files/10823388/dlsstweaks-0.123.12beta2.zip)
This adds an OverrideDlssDll
option which can try making the game load DLSS from a different path, can help with some awful launchers that would always overwrite the nvngx_dlss.dll file, now you could put 3.1.1 as nvngx_dlss_new.dll and use OverrideDlssDll
to load that in instead - or keep your DLSS DLL somewhere like C:\bin\nvngx_dlss.dll
and use DLSSTweaks across all your games to load it in 😄
Also changed how INI file is loaded in if you have the DLL somewhere different to the EXE, by default it'll load dlsstweaks.ini from next to the DLL itself, but if a dlsstweaks.ini file exists next to game EXE it'll use that instead, should help with using this with global injector tools like SpecialK (eg. you could keep a global config INI next to the dlsstweaks.dll file, and then for per-game configs you can create one next to the game EXE itself too)
This also updated safetyhook
to latest version, the latest safetyhook did have some weird deadlock issues with Atomic Heart though which should hopefully be fixed now, tried a couple more games and didn't notice any other problem, but if anyone finds a game that's broken with this please let me know!
Hogwarts legacy is still not working with 0.123.12beta3. It gets stuck at the warning text at the start of the game. Maybe I should oppen a new issue for this?
Could anyone having issues with Hogwarts try the build at https://github.com/emoose/DLSSTweaks/issues/28#issuecomment-1445029607 ? Maybe the deadlock mentioned there is responsible here.
0.123.12beta4 release: dlsstweaks-0.123.12beta4.zip
This updated safetyhook to latest version, and also uses a new method of watching for the NVNGX library via LdrRegisterDllNotification
, should both be able to help with compatibility with certain games & apps.
Would be interested in whether that helps with the Hogwarts Legacy issues at all, or if there's any regressions with it breaking any games, seemed to still work fine with the ones I test with at least.
It seems that with 0.123.12beta4 wogwarts legacy stops working, sometimes it does not even go t the starting warnings, others it gets to the warnings and it crashes. Seems like a regression from 0.123.12beta3a.
Found that CP2077 also crashed on launch with beta4, figured a way to stop that by rearranging some code, maybe that could help with Hogwarts too, here's a build if you'd like to test: dlsstweaks-0.123.12beta4a.zip
(sadly with CP2077 there's now a crash if CyberEngineTweaks DLL is also loaded in, wasn't any issue with that before - guessing maybe there's some incompatibility with how the new safetyhook freezes threads & how CET's minhook does it, but haven't really found the cause yet...)
The beta3a fix was mostly a hack that made the hooks more unsafe, would probably cause issues in some other games :/
E: might be an issue with OverrideDlssHud
in this build, you can use the reg file at https://github.com/NVIDIA/DLSS/blob/main/utils/ngx_driver_onscreenindicator.reg to force it to show (change dword:00000001
to dword:00000400
to let it work with the non-dev DLSS)
and https://github.com/NVIDIA/DLSS/blob/main/utils/ngx_driver_onscreenindicator_off.reg to turn it off again.
dlsstweaks-0.123.12beta4a.zip crashes at the start with hogwarts legacy or gets stuck in the warning text.
@jpgsantos ah darn, sorry about that, well I might have found root cause for most of the crashes, any chance you can try this out?
dlsstweaks-0.123.12beta5.zip (old: dlsstweaks-0.123.12beta4b.zip)
For me that seems to fix CP2077 properly at least, both vanilla and with CyberEngineTweaks in place, so really hoping this'll help here too.
@jpgsantos ah darn, sorry about that, well I might have found root cause for most of the crashes, any chance you can try this out?
dlsstweaks-0.123.12beta5.zip (old: dlsstweaks-0.123.12beta4b.zip)
For me that seems to fix CP2077 properly at least, both vanilla and with CyberEngineTweaks in place, so really hoping this'll help here too.
Hi @emoose regarding Hogwarts Legacy. Beta 4 completely broke startup, the game would not run at all past the warning screen, crash and send a report back to devs (worse than before, because it is causing a crash now).
Beta 5 fixed that issue, and we are back to running the game a few times until it works. But at least it works like before. Beta 4 was completely broken with my settings below.
Also, not sure if this helps with finding a solution but I noticed in windowed mode while looking at the processes for the game, after the game boots it calls on nvngx_update.exe like in this image below for a second or two:
https://i.imgur.com/OmafDpb.jpg
As for my .ini tweaks, here they are:
[DLSS]
OverrideAutoExposure = 1
OverrideAppId = true
OverrideDlssHud = -1
DisableDevWatermark = true
WatchIniUpdates = true
[DLSSQualityLevels]
Enable = true
UltraPerformance = 0.5
Performance = 0.6
Balanced = 0.66666667
Quality = 0.75
[DLSSPresets]
DLAA = F
Quality = F
Balanced = F
Performance = F
UltraPerformance = F
AND here is the log when the game WORKS:
[2023-02-28 11:54:18.006] [info] DLSSTweaks v0.123.12, by emoose: DLL wrapper loaded, watching for DLSS library load.
[2023-02-28 11:54:18.007] [info] Game path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\HogwartsLegacy.exe
[2023-02-28 11:54:18.007] [info] DLL path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\dxgi.dll
[2023-02-28 11:54:18.007] [info] Config path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\dlsstweaks.ini
[2023-02-28 11:54:18.007] [info] ---
[2023-02-28 11:54:18.007] [info] Watching for nvngx via LdrRegisterDllNotification
[2023-02-28 11:54:25.304] [info] Applied _nvngx.dll DLL export hooks, waiting for game to call them...
[2023-02-28 11:54:26.112] [info] DLSS functions found & parameter hooks applied!
[2023-02-28 11:54:26.112] [info] Settings:
[2023-02-28 11:54:26.112] [info] - ForceDLAA: false
[2023-02-28 11:54:26.112] [info] - OverrideAutoExposure: enable
[2023-02-28 11:54:26.112] [info] - OverrideAppId: true
Here is the LOG when the game FAILS to load and stays on the warning screen:
[2023-02-28 12:09:08.494] [info] DLSSTweaks v0.123.12, by emoose: DLL wrapper loaded, watching for DLSS library load.
[2023-02-28 12:09:08.494] [info] Game path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\HogwartsLegacy.exe
[2023-02-28 12:09:08.494] [info] DLL path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\dxgi.dll
[2023-02-28 12:09:08.494] [info] Config path: C:\Program Files (x86)\Steam\steamapps\common\Hogwarts Legacy\Phoenix\Binaries\Win64\dlsstweaks.ini
[2023-02-28 12:09:08.494] [info] ---
[2023-02-28 12:09:08.494] [info] Watching for nvngx via LdrRegisterDllNotification
[2023-02-28 12:09:17.404] [info] Applied _nvngx.dll DLL export hooks, waiting for game to call them...
Hope this information helps in finding a solution.
@Sinkingsun ah interesting info, thanks, wonder if that updater call might be causing DLSS to unload and then reload back in...
I posted a build at https://github.com/emoose/DLSSTweaks/issues/33#issuecomment-1446890490 which should improve support for it being unloaded/reloaded, could you give it a try and see if it helps at all?