-
Bug
-
Resolution: Fixed
-
1.16.5, 1.17 Pre-release 3, 1.17 Pre-release 4, 1.17 Pre-release 5, 1.17 Release Candidate 1, 1.17, 1.17.1 Pre-release 1, 1.17.1 Release Candidate 1, 1.17.1, 21w42a, 21w44a, 1.18 Pre-release 4, 1.18.1, 1.18.2, 22w16a, 22w16b, 1.19 Pre-release 3, 1.19 Release Candidate 1, 1.19 Release Candidate 2, 1.19, 1.19.2, 1.19.3, 23w07a
-
Plausible
-
Rendering
-
Low
-
Platform
The method com/mojang/blaze3d/vertex/PoseStack#scale is broken in some situations:
1. If one or three of the scales are negative, the normal matrix will not be scaled correctly. The fix for this is to take the absolute value (Math.abs) of the argument passed into the net/minecraft/util/Mth#fastInvCubeRoot method. Additionally, net/minecraft/util/Mth#fastInvCubeRoot does not work for negative numbers, but fixing it does not solve this issue because it causes the matrix to be inverted.
2. If all scales are equal and negative, the normal matrix will not be scaled correctly. For this case, all normals should be inverted, but in reality nothing happens. The fix for this is to return after the normal matrix is inverted (normal.mul(-1.0f)).
- relates to
-
MC-176864 Mirrored custom model scaling does not render correctly
- Reopened
-
MC-187616 Totems rendered too dark for a second after being used
- Resolved
-
MC-260099 Sniffer's snout shading changes during sniffing
- Resolved
-
MC-239084 Item pickup animation is darker than the actual item model
- Resolved