Explorar el Código

tweaked point filled circle shader

Alexander Rose hace 6 años
padre
commit
78ee23a8c8
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      src/mol-gl/shader/point.frag

+ 2 - 2
src/mol-gl/shader/point.frag

@@ -27,9 +27,9 @@ void main(){
 
         #ifdef dPointFilledCircle
             float dist = distance(gl_PointCoord, center);
-            float alpha = 1.0 - smoothstep(radius - uPointEdgeBleach * 2.0, radius, dist);
+            float alpha = 1.0 - smoothstep(radius - uPointEdgeBleach, radius, dist);
+            if (alpha < 0.0001) discard;
             gl_FragColor.a *= alpha;
-            if (gl_FragColor.a < 0.1) discard;
         #endif
 
         #pragma glslify: import('./chunks/apply-marker-color.glsl')