Polygon outline

 from Red Blob Games
30 Jul 2017

I wanted to see if I could draw an outline around a polygon by using the distance to the exterior edge.

The problem is that at a corner, we actually need the distances to both edges. And that means we need to pass three edges to the shader. Hm.

If the outlines are thin and the angles are similar (e.g. a centroid dual mesh), it should be ok.

Email me , or tweet @redblobgames, or comment: