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

Vertex ordering in entity rendering is different, breaking core shaders #2745

Closed
ArubikU opened this issue Sep 12, 2024 · 3 comments
Closed
Labels
A-vanilla-parity Area: Vanilla parity R-pending-release Resolution: Pending release T-bug Type: Bug

Comments

@ArubikU
Copy link

ArubikU commented Sep 12, 2024

Bug Description

Sodium load all the entity shaders correctly but changuing a bit the faces id`s causing some incompatibilities with "core shaders"

Expected behavior:
image

Actual:
image

Reproduction Steps

Pack for sodium example.zip
example_skin

  1. Install the Resourcepack
  2. Apply the example skin what add wings

In vanilla the wings will be rendered correctly in sodium fail on the read of faces
Method use in vertex to detect faces: int face = gl_VertexID / 4 % 6;
Vanilla faces i identify:
#define BOTTOM_FACE 0
#define TOP_FACE 1
#define RIGHT_FACE 2
#define NORTH_FACE 3
#define LEFT_FACE 4
#define SOUTH_FACE 5

Log File

latest.log

Crash Report

crash-2024-09-12_17.26.57-client.txt

@ArubikU ArubikU added the S-needs-triage Status: Needs triage label Sep 12, 2024
@douira
Copy link
Collaborator

douira commented Sep 12, 2024

I want to note that this is an issue with the entity data provided by sodium to the resource pack's core shader and not a matter of getting sodium to load a pack's terrain core shaders (since this isn't terrain). This was misunderstood in the preceding discussion on discord multiple times.

@jellysquid3
Copy link
Member

It would probably be enough to fix this issue if the ordering of constants here were changed to match Minecraft.

@jellysquid3
Copy link
Member

jellysquid3 commented Sep 22, 2024

However, it is possible that future versions of Sodium will discard back-facing triangles when rendering entities, and that core shaders which rely on this specific ordering will be broken once again.

We do not support core shaders and we cannot guarantee that relying on extremely specific behavior like this will continue to work.

@jellysquid3 jellysquid3 added T-bug Type: Bug A-vanilla-parity Area: Vanilla parity and removed S-needs-triage Status: Needs triage labels Sep 22, 2024
@jellysquid3 jellysquid3 changed the title Sodium changue Vertex Faces Ids on Entity Shaders Vertex ordering in entity rendering is different, breaking core shaders Sep 22, 2024
@jellysquid3 jellysquid3 added A-core-shaders Area: Core shader replacement and removed A-core-shaders Area: Core shader replacement labels Sep 22, 2024
@jellysquid3 jellysquid3 added the R-pending-release Resolution: Pending release label Sep 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-vanilla-parity Area: Vanilla parity R-pending-release Resolution: Pending release T-bug Type: Bug
Projects
None yet
Development

No branches or pull requests

3 participants