Square Circle Spiral Illusion
✓ Published0🌍 Public
Mmbostock
Last edited Feb 9, 2016
Created on Nov 22, 2011
Six concentric rings of small squares rotate at different speeds via SVG transforms, creating a spiral-like square illusion against a gray background. Alternate squares are stroked white for contrast. The animation uses `d3.timer` and `d3.selectAll` with `attr("transform")` to update rotation based on elapsed time, while each ring’s squares are generated from `d3.range` and positioned with `translate` and `rotate`. The code runs on D3 v3 and relies on SVG `rect` elements.
AI-generated descriptiongpl-3.0 Licensed