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

Make fog-enable driven by uniform instead of fragment shader flag bit #16628

Merged
merged 3 commits into from
Jan 4, 2023

Conversation

hrydgard
Copy link
Owner

Part of #16567, to be merged after 1.14.x .

No way this is a perf regression on any hardware, heh. Really good reduction of the fragment shader count in several big games, leading to less shader stutter.

Not sure what the best "flag values" in the coef would be, or if we should consume an extra bool.

Will bump the shader cache ID when this is merged together with the other similar changes.

@hrydgard hrydgard added the GE emulation Backend-independent GPU issues label Dec 19, 2022
@hrydgard hrydgard added this to the v1.15.0 milestone Dec 19, 2022
@hrydgard hrydgard force-pushed the remove-fog-fshader-flag branch from 9979a4f to 69f6109 Compare December 30, 2022 21:09
@hrydgard hrydgard marked this pull request as ready for review December 30, 2022 21:09
@hrydgard hrydgard force-pushed the remove-fog-fshader-flag branch from 69f6109 to 3dbe69f Compare January 4, 2023 09:18
@hrydgard hrydgard enabled auto-merge January 4, 2023 09:24
@hrydgard hrydgard disabled auto-merge January 4, 2023 09:24
@hrydgard hrydgard merged commit 10dee90 into master Jan 4, 2023
@hrydgard hrydgard deleted the remove-fog-fshader-flag branch January 4, 2023 10:01
@@ -9,7 +9,7 @@
enum : uint64_t {
DIRTY_BASE_UNIFORMS =
DIRTY_WORLDMATRIX | DIRTY_PROJTHROUGHMATRIX | DIRTY_VIEWMATRIX | DIRTY_TEXMATRIX | DIRTY_ALPHACOLORREF |
DIRTY_PROJMATRIX | DIRTY_FOGCOLOR | DIRTY_FOGCOEF | DIRTY_TEXENV | DIRTY_STENCILREPLACEVALUE |
DIRTY_PROJMATRIX | DIRTY_FOGCOLOR | DIRTY_TEXENV | DIRTY_STENCILREPLACEVALUE |
Copy link
Collaborator

Choose a reason for hiding this comment

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

Hm, should DIRTY_FOGCOEFENABLE be here? Isn't it still in the base uniforms?

-[Unknown]

Copy link
Owner Author

Choose a reason for hiding this comment

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

Hm, yes, it seems to be an oversight. Will fix.

hrydgard added a commit that referenced this pull request Jan 5, 2023
hrydgard added a commit that referenced this pull request May 9, 2023
hrydgard added a commit that referenced this pull request May 9, 2023
Revert "Merge pull request #16628 from hrydgard/remove-fog-fshader-flag"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GE emulation Backend-independent GPU issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants