don't fade grid axes depending on camera angle

This commit is contained in:
Nick Fisher
2025-07-09 10:46:37 +08:00
parent ee176d2684
commit ef7ba24ecc
5 changed files with 2134 additions and 2187 deletions

View File

@@ -108,10 +108,13 @@ fragment {
1.0
);
color.rgb = (axes.x < 1e-8) ? color.rgb : AXIS_COLOR_X;
color.rgb = (axes.z < 1e-8) ? color.rgb : AXIS_COLOR_Z;
material.baseColor = color * gridAlpha;
if(axes.x > 1e-8) {
material.baseColor = vec4(AXIS_COLOR_X, 1.0);
} else if(axes.z > 1e-8) {
material.baseColor = vec4(AXIS_COLOR_Z, 1.0);
} else {
material.baseColor = color * gridAlpha;
}
}
}

View File

@@ -8,5 +8,5 @@ GRID_PACKAGE:
GRID_GRID_OFFSET:
.int 0
GRID_GRID_SIZE:
.int 50913
.int 49793

View File

@@ -8,5 +8,5 @@ _GRID_PACKAGE:
_GRID_GRID_OFFSET:
.int 0
_GRID_GRID_SIZE:
.int 50913
.int 49793

File diff suppressed because it is too large Load Diff