馃О Using ddx and ddy: Mipmaps and Smooth Edges
The two uses of ddx and ddy you鈥檒l meet most: choosing a texture鈥檚 mipmap level, and smooth edges at any zoom with fwidth. With live WebGL demos.
The two uses of ddx and ddy you鈥檒l meet most: choosing a texture鈥檚 mipmap level, and smooth edges at any zoom with fwidth. With live WebGL demos.
Why edges look like staircases, and the three classic fixes: draw more pixels (SSAA), test more points but shade once (MSAA), or blur the edges afterwards (FXAA). Compare them on your own GPU.
Store the distance to a letter鈥檚 edge in a texture instead of the letter itself, and it stays razor sharp when magnified, with outlines, glows and bold text for free. Part 3 of the signed distance fields series.