NVIDIA-RTX / NVIDIA-RTX/Streamline
[DLSS-G] Add runtime gating of IDXGISwapChainProvider to prevent early PresentBefore hook
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 1.2k
- Forks
- 159
- PR merge metrics
- No merged PRs in 30d
Description
We're integrating DLSS-G (DLSS Frame Generation) using the 4.0.2 version into a real-time Unreal Engine 5.5.4 game and encountering a critical issue:
🔥 Issue Summary
When the DLSS-G plugin is loaded (even with all activation cvars set to 0), the Streamline framework (version v2.7.30.afa89bde) immediately registers a DXGI PresentBefore hook via IDXGISwapChainProvider.
This causes a GPU hang in packaged builds when startup movies (e.g., Bink) are playing — even though DLSS-G is disabled in all config cvars.
🧪 Repro Conditions
-
DLSS-G plugin is
"Enabled": truein.uproject(required to cook shaders likeFStreamlineVelocityCombineCS) -
DefaultEngine.inihas:r.Streamline.Enable=0 r.Streamline.Load.DLSSG=0 r.Streamline.DLSSG.Enable=0- Bink movie plugin plays a fullscreen startup movie
- No DLSS-G features are initialized or used
- On startup: GPU crash (device removed during early DXGI present)
✅ Expected Behavior
If
r.Streamline.Load.DLSSG=0, the DLSS-G module should not register any DXGI hooks duringStartupModule()or plugin load time.This would allow us to:
- Cook DLSS-G shaders
- Delay plugin activation manually (e.g., after movie playback)
- Avoid early DXGI interference
🚧 Current Workarounds Attempted
- Delayed
LoadModuleChecked()→ fails due to missing cooked shaders (requires"Enabled": true) - Runtime cvar toggling → DXGI hook already registered too early
- Tried
Optional: trueandEnablePlugins.Add(...)— no effect - Full Streamline SDK integration → not applicable to DLSS-G (precompiled only)
🧩 Suggested Solution
Please consider exposing a cvar like:
r.Streamline.DelayHookRegistrationUntilFirstPresent=1
or a deferred DXGI hook registration like:if (r.Streamline.Load.DLSSG != 0) { RegisterIDXGISwapChainProvider(); }
Torbjörn Söderman
Technical Director, GOALS
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the DLSS-G module's StartupModule() and trace where IDXGISwapChainProvider or the PresentBefore hook is registered. Check how r.Streamline.Load.DLSSG is read during plugin loading, then reproduce the packaged startup movie case with the cvar disabled and enabled. Done means no early hook when disabled while normal hook registration remains possible when enabled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, unreal-engine
- Domain
- computer-graphics, game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100