This updates the pattern-dots style with a refactored transition between zoom levels. In both versions, the transition "splits" a dot into three other dots which take their place in a "brick" pattern. In the old style, the new split dots shrink briefly before enlarging as they take their final position:
I've simplified the function while (afaik) not removing any functionality, added a couple of comments, made some parameters more clear, and kept the new "split" dots from shrinking, which maintains pattern density better across zoom levels:
This updates the
pattern-dots
style with a refactored transition between zoom levels. In both versions, the transition "splits" a dot into three other dots which take their place in a "brick" pattern. In the old style, the new split dots shrink briefly before enlarging as they take their final position:This caused a momentary lightening of the fill when crossing integer zoom levels, as the density of the pattern dips briefly. View this effect by zooming in and out here: https://mapzen.com/tangram/view/?api=5/1227#13.6333/45.2459/-114.7776
I've simplified the function while (afaik) not removing any functionality, added a couple of comments, made some parameters more clear, and kept the new "split" dots from shrinking, which maintains pattern density better across zoom levels:
View it in action here: https://mapzen.com/tangram/view/?api=5/1228#15.2625/45.2478/-114.7737