Skip to content

GS/DX11: Backport ds as rt from GL for depth feedback.#14603

Merged
lightningterror merged 1 commit into
masterfrom
gs_dx11_ds_as_rt
Jun 25, 2026
Merged

GS/DX11: Backport ds as rt from GL for depth feedback.#14603
lightningterror merged 1 commit into
masterfrom
gs_dx11_ds_as_rt

Conversation

@lightningterror

@lightningterror lightningterror commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

Description of Changes

GS/DX11: Backport ds as rt from GL for depth feedback.

Doing gpu depth copies is quite slower on dx11, so let's use the ds as rt behavior from GL which would allow us to treat them as rt copies instead which are faster.

Even tho we are doing extra copies since we are copying the depth as rt it's still faster than plain gpu depth copies.

Rationale behind Changes

Optimization, speed.

Suggested Testing Steps

Test AA1, AAT games such as FFX, Everybody's golf and more on dx11, see if it's faster now compared to master, both tests without rov.

Did you use AI to help find, test, or implement this issue or feature?

No.

@TJnotJT TJnotJT left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look fine, haven't personally tested.

@TJnotJT

TJnotJT commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

Actually, one thing to possibly double check is that the blend state is completely cleared with DS as RT. I got validation errors on GL if there were any dual source blend flags remaining in the state, even if blending was disabled. I'm not sure if this is relevant to DX11.

@JordanTheToaster JordanTheToaster left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested a few games and did a few benchmarks in DX11.

Image image

Doing gpu depth copies is quite slower on dx11, so let's
use the ds as rt behavior from GL which would allow us
to treat them as rt copies instead which are faster.
@lightningterror lightningterror merged commit 66ea4c4 into master Jun 25, 2026
29 checks passed
@lightningterror lightningterror deleted the gs_dx11_ds_as_rt branch June 25, 2026 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants