Skip to content
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

Vulkan: Use depth clamping, where available #10454

Merged
merged 5 commits into from
Dec 27, 2017

Conversation

unknownbrackets
Copy link
Collaborator

This allows depth clamping to work correctly, and uses the full 24 bits of depth when it's available.

According to vulkan.gpuinfo.org, some mobile chips support this, although it's mostly just desktop.

-[Unknown]

Was slightly off in the accurate depth path.
Just in case some game stores it somewhere, but also makes it simpler to
write tests against hardware.
This fixes, for example, Shadow of Destiny, even without the hack.
@@ -37,6 +37,9 @@ alignas(16) GPUgstate gstate;
// Let's align this one too for good measure.
alignas(16) GPUStateCache gstate_c;

// For save state compatibility.
static int savedContextVersion = 1;
Copy link
Owner

Choose a reason for hiding this comment

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

This should be set to 1 somewhere when a game is started, right? Otherwise it could leak over to the second game you run in a session..

Should really rearchitect the whole emu to avoid all these globals... oh well.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Oops, yes, thanks.

Once you have one global, it's kinda hard to avoid more.

-[Unknown]

@hrydgard hrydgard merged commit ea50561 into hrydgard:master Dec 27, 2017
@hrydgard
Copy link
Owner

Seems Adreno is stepping up and implementing a lot of optional features and extensions in later drivers. Mali lagging behind.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants