Conversation
Width/Height 0 in the swapchain desc means DXGI uses the window size, so these are real game swapchains and should be wrapped.
gabrielmaialva33
added a commit
to gabrielmaialva33/OptiScaler_DLSSNR
that referenced
this pull request
Sep 30, 2026
Width/Height 0 in a swapchain desc tells DXGI to take the window's size, so these are real game swapchains. The `< 100` overlay check sent them down the unwrapped path: no menu, no OptiFG, and for a D3D11 title no bridge, even though every bridge creation path already resolves a zero extent against the game window (Dx11wDx12::ResolveZeroExtent) right after this check. Upstream PR optiscaler#1183 (kebas3, 8abf6d7) fixes the four checks in DxgiFactory_Hooks.cpp; its text is used verbatim there so the conflict is empty when it merges. The same check exists five more times and the PR misses them: the two CoreWindow variants in DxgiFactory_Hooks.cpp and CreateSwapChain / CreateSwapChainForHwnd / CreateSwapChainForCoreWindow in DxgiFactory_WrappedCalls.cpp, the path a wrapped factory takes. All nine now read the same. Ported from optiscaler#1183 (kebas3/OptiScaler@8abf6d7f). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Some games pass Width/Height = 0 when creating their swapchain, which tells DXGI to use the window size. The
< 100overlay check treats that as an overlay, so the game's main swapchain never gets wrapped and the menu and OptiFG don't work.Hit this in Soulframe (DX12). The log only shows
CreateSwapChainForHwnd Overlay call!for the game's swapchain. With this change it logsWidth: 0, Height: 0, gets wrapped, and the menu and FSR FG work. #1141 (Helldivers 2) looks like the same issue, same lone "Overlay call!" in DX12.