-
Notifications
You must be signed in to change notification settings - Fork 832
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
Translucency sort using compute shaders #963
Conversation
5950bb3
to
6584913
Compare
b1c657f
to
33d8080
Compare
33d8080
to
0448122
Compare
Gave it a quick try: it's able to be just merged into the 1.18 branch without changes/conflicts, and from some quick testing, it seems to be fully working as well. 👍 |
Copying Jelly's comments on this PR from discord for accessibility:
|
Currently requires the following patch to compile when rebased on 1.18.x/dev
Note that this may cause some allocation overhead. Edit: do not use as-is, this patch trashes performance horribly, a solution must be found to remove the extra allocation instead. |
How do I add this to my game? |
Hi, has any progress been made/is there anywhere to track progress on the task list linked by amnotbananaama? (or any other related efforts to help merge this into upstream?) |
Might be able to clone https://github.com/MESLewis/sodium-fabric/tree/translucency-sort and follow the build steps just be very aware it is most likely very unstable |
How do I use this? |
You can't at the moment, this was work in progress and has been left dormant, thus it is now incompatible with recent Sodium. |
Implementation directly derived from CaffeineMC/sodium#963 Some changes were made to improve frametimes on low-end systems This is still very experimental, and is not enabled by default
Fixes #38 for supported hardware
Adds support for sorting translucent geometry by using OpenGL compute shaders.
Either OpenGL 4.3+ or OpenGL 4.2+ with both
ARB_shader_storage_buffer_object
andARB_compute_shader
is required for this option to function.Before (note that some parts of slime blocks and stained glass are not drawn):


After (all translucent geometry is sorted so it is drawn correctly):
Note: Region draw order is sometimes incorrect. This is existing behavior not caused by these changes.