File tree Expand file tree Collapse file tree
java/org/visuals/legacy/animatium/util/rendering
assets/animatium/shaders/core Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -388,7 +388,7 @@ public DynamicTransforms withModelOffset(Vector3f vector3f) {
388388 }
389389
390390 public Matrix4f getModelViewMatrix () {
391- return this .modelViewMatrix == null ? new Matrix4f (RenderSystem .getModelViewMatrixCopy ()) : this .modelViewMatrix ;
391+ return this .modelViewMatrix == null ? new Matrix4f (RenderSystem .getModelViewStack ()) : this .modelViewMatrix ;
392392 }
393393
394394 public Matrix4f getTextureMatrix () {
Original file line number Diff line number Diff line change @@ -7,8 +7,6 @@ accessible class com/mojang/blaze3d/pipeline/MainTarget$Dimension
77accessible class net/minecraft/client/renderer/CloudRenderer$RelativeCameraPos
88accessible class net/minecraft/client/gui/components/AbstractSelectionList$Entry
99
10- accessible class com/mojang/blaze3d/opengl/GlDevice
11-
1210accessible method com/mojang/blaze3d/pipeline/MainTarget$Dimension listWithFallback (II)Ljava/util/List;
1311accessible field net/minecraft/client/renderer/item/ItemStackRenderState displayContext Lnet/minecraft/world/item/ItemDisplayContext;
1412accessible method net/minecraft/client/gui/components/debug/DebugScreenEntries register (Lnet/minecraft/resources/Identifier;Lnet/minecraft/client/gui/components/debug/DebugScreenEntry;)Lnet/minecraft/resources/Identifier;
Original file line number Diff line number Diff line change @@ -10,12 +10,14 @@ out float cylindricalVertexDistance;
1010out float sphericalVertexDistance;
1111
1212void main() {
13- gl_Position = ProjMat * ModelViewMat * vec4 (Position, 1.0 );
13+ vec4 eye = ModelViewMat * vec4 (Position, 1.0 );
1414#ifdef PLANAR_FOG
15- cylindricalVertexDistance = gl_Position .z;
16- sphericalVertexDistance = gl_Position .z;
15+ float dist = - eye.z;
16+ cylindricalVertexDistance = dist;
17+ sphericalVertexDistance = dist;
1718#else
1819 cylindricalVertexDistance = fog_cylindrical_distance(Position);
1920 sphericalVertexDistance = fog_spherical_distance(Position);
2021#endif
22+ gl_Position = ProjMat * eye;
2123}
You can’t perform that action at this time.
0 commit comments