-
Notifications
You must be signed in to change notification settings - Fork 892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rework swapchain management #4609
Open
doitsujin
wants to merge
22
commits into
master
Choose a base branch
from
swapchain-rework
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+1,583
−898
Conversation
This file contains 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
doitsujin
force-pushed
the
swapchain-rework
branch
5 times, most recently
from
January 13, 2025 14:15
cb57e40
to
22ccf41
Compare
Massive cleanup reduce code duplication between D3D11 and D3D9, and introduce a sane path to pass data around. Implicit swap chain recreation is now entirely transparent to the frontends.
doitsujin
force-pushed
the
swapchain-rework
branch
from
January 13, 2025 16:19
22ccf41
to
711fb42
Compare
The swap chain blitter can deal with the conversion.
Needed for D3D8 due to implicit swapchain shenanigans.
This will be necessary for non-linear color spaces to get proper blending.
Also adds a separate set of shaders for the software cursor, provided it can be drawn directly with alpha blending.
For sRGB, using a native sRGB format allows the swapchain blitter to use a more efficient code path for drawing the HUD. Also allow RGB9E5 for sRGB and HDR10.
doitsujin
force-pushed
the
swapchain-rework
branch
from
January 13, 2025 22:56
711fb42
to
bc9c123
Compare
May fix some issues in case the WSI implementation can return SUBOPTIMAL from present but not acquire. Also ensure to keep state consistent.
doitsujin
force-pushed
the
swapchain-rework
branch
from
January 14, 2025 14:49
b179388
to
c6a21f5
Compare
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.
Big refactor that moves a lot of responsibility to the backend, where it should have been in the first place.
Key changes:
acquireNextImage
call.Needs lots of testing, especially in D3D9 apps since there are so many weird edge cases wrt swapchain usage.