Snapping a Square grid to an outline

This component can also morph all sorts of geometry, including meshes with colours, so I think all sorts of applications are possible…
imagemorph