Myth: Vector graphics on GPU is hard because GPUs only know how to draw triangles, not curves. In fact, anyone who has touched a pixel shader in Unity can make a GPU draw a filled circle…
-
Show this thread
-
Rather, vector graphics on GPU is hard because GPUs don’t know how to draw filled *polygons*. That’s because fill rules are inherently sequential: whether a pixel is filled depends on every pixel before it in the scanline.
2 replies 5 retweets 43 likesShow this thread -
Replying to @pcwalton
(Signed) distance fields are a different way of approaching this. Fill a pixel where distance is negative, small distances are used for anti aliasing by eg making the edges fade to transparency. They have different problems though, not a panacea :)
2 replies 1 retweet 2 likes -
Ray tracing is another, if you can do analytical or numerical ray vs 2d shape tests for the shapes you want. (When RTing against a mesh though, it basically degrades to raster)
1 reply 0 retweets 1 like
Yeah, another way of stating the problem is that each ray can hit a potentially unbounded number of edges when you consider arbitrary shapes.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.