Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Some more material system clean-up #1563

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

Merged
merged 3 commits into from
Mar 3, 2025

Conversation

VReaperV
Copy link
Contributor

@VReaperV VReaperV commented Feb 24, 2025

These are mostly changes that I picked from #1559.

Previously only the material system used compute shaders at all, but now that other systems will be using them, all this stuff needs to be moved to another shader. Otherwise the other shaders would fail to compile, or all of them would require a bunch of macros to check for it.

Also moved the material system per-frame compute dispatches to StartFrame() since they work there now.

@VReaperV VReaperV force-pushed the material-cleanup branch 3 times, most recently from b293a05 to 7f9ea93 Compare March 1, 2025 18:42
@DolceTriade
Copy link
Contributor

DolceTriade commented Mar 2, 2025

Tested and didn't notice any regressions, though I did spot a material issue: #1572

But this happens with or without this PR (and on vanilla 0.55.2)

LGTM (but didn't do any meaningful code review)

@slipher
Copy link
Member

slipher commented Mar 2, 2025

The StartFrame change seems to mess up time-dependent stuff a bit (tcMod rotate, tcMod scroll, light styles). Like the time is off by 1 frame. On master if I take a screenshot at a given game time, I get the same result with or without material system. With this branch it is a bit off.

VReaperV added 3 commits March 2, 2025 16:34
Previously only the material system used compute shaders at all, but now that other systems will be using them, all this stuff needs to be moved to another shader. Otherwise the other shaders would fail to compile, or all of them would require a bunch of macros to check for it.
@VReaperV
Copy link
Contributor Author

VReaperV commented Mar 2, 2025

The StartFrame change seems to mess up time-dependent stuff a bit (tcMod rotate, tcMod scroll, light styles). Like the time is off by 1 frame. On master if I take a screenshot at a given game time, I get the same result with or without material system. With this branch it is a bit off.

Oh, that's because it's using the incorrect refdef there. I've removed that change for now.

@VReaperV
Copy link
Contributor Author

VReaperV commented Mar 2, 2025

Also added a fix for a crash on maps where MST_FLARE surfaces are present, since it's a small bug fix for aa crash on master and a small pr, so makes sense to circumvent the 24h rule.

@slipher
Copy link
Member

slipher commented Mar 3, 2025

LGTM

@VReaperV VReaperV merged commit 515decd into DaemonEngine:master Mar 3, 2025
9 checks passed
@VReaperV VReaperV deleted the material-cleanup branch March 3, 2025 05:34
@github-project-automation github-project-automation bot moved this from In Progress to Done in Material system Mar 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants