-
Notifications
You must be signed in to change notification settings - Fork 5
/
dots.yaml
31 lines (31 loc) · 905 Bytes
/
dots.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
styles:
lines-dots:
doc:
author:
name: Patricio Gonzalez Vivo
twitter: patriciogv
version: 0.0.1
tangram-version: 0.0.7
licence: MIT
description: |
Apply a dot pattern to a line
ui:
shaders:
defines:
DOTS_SIZE:
type: number
label: Size
range:
min: 0.
max: 1.
step: 0.01
base: lines
texcoords: true
blend: overlay
shaders:
defines:
DOTS_SIZE: .05
blocks:
color: |
vec2 st = fract(v_texcoord.xy)-.5;
color.a = 1.- step(DOTS_SIZE, dot(st,st)*2.);