Spaces:
Paused
Paused
Download node_modules/@plotly/mapbox-gl/src/shaders/circle.fragment.glsl from Leon4gr45/UserSyncFrontend: direct link, hf CLI and curl.
- Browser
- Download file 1.29 kB
-
https://huggingface.co/spaces/Leon4gr45/UserSyncFrontend/resolve/main/node_modules/%40plotly/mapbox-gl/src/shaders/circle.fragment.glsl
- Command line
-
hf download hf://spaces/Leon4gr45/UserSyncFrontend/node_modules/@plotly/mapbox-gl/src/shaders/circle.fragment.glsl
-
curl -L -o circle.fragment.glsl https://huggingface.co/spaces/Leon4gr45/UserSyncFrontend/resolve/main/node_modules/%40plotly/mapbox-gl/src/shaders/circle.fragment.glsl
1.29 kB
| varying vec3 v_data; | |
| void main() { | |
| vec2 extrude = v_data.xy; | |
| float extrude_length = length(extrude); | |
| lowp float antialiasblur = v_data.z; | |
| float antialiased_blur = -max(blur, antialiasblur); | |
| float opacity_t = smoothstep(0.0, antialiased_blur, extrude_length - 1.0); | |
| float color_t = stroke_width < 0.01 ? 0.0 : smoothstep( | |
| antialiased_blur, | |
| 0.0, | |
| extrude_length - radius / (radius + stroke_width) | |
| ); | |
| gl_FragColor = opacity_t * mix(color * opacity, stroke_color * stroke_opacity, color_t); | |
| gl_FragColor = vec4(1.0); | |
| } | |