From 9ed7d7ab2fc70f971aa18d61f5ea04b346c836a3 Mon Sep 17 00:00:00 2001 From: Ilion Beyst Date: Sun, 6 Nov 2022 21:44:56 +0100 Subject: render planet names --- web/pw-visualizer/assets/shaders/frag/msdf.glsl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'web/pw-visualizer/assets/shaders/frag') diff --git a/web/pw-visualizer/assets/shaders/frag/msdf.glsl b/web/pw-visualizer/assets/shaders/frag/msdf.glsl index 5d2325b..23bacfc 100644 --- a/web/pw-visualizer/assets/shaders/frag/msdf.glsl +++ b/web/pw-visualizer/assets/shaders/frag/msdf.glsl @@ -24,6 +24,7 @@ void main() { float sd = median(msd.r, msd.g, msd.b); float screenPxRange = max(u_distanceRange, scale); float screenPxDistance = screenPxRange*(sd - 0.5); - float opacity = clamp(screenPxDistance + 0.5, 0.0, 1.0); + // float opacity = clamp(screenPxDistance + 0.5, 0.0, 1.0); + float opacity = clamp(0.0, 1.0, screenPxDistance + 0.5); gl_FragColor = vec4(u_fgColor.rgb, u_fgColor.a * opacity); } \ No newline at end of file -- cgit v1.2.3