I was trying smooth the edge using fwidth and smoothstep for anti alias and it obviously works for particles but I just don’t how to get the distance to the edge of the sdf shape in this case a sphere radius of 1. I found some blog posts about it but I think it just comes down to storing a variable for distance to the edge then we can smooth or clamp the edges.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Shader to create an offset, inward-growing stroke? | 25 | 8227 | October 11, 2019 | |
How to get sharp edge with particles | 9 | 450 | June 20, 2024 | |
How to change the gap of the sawtooth problem | 10 | 899 | February 22, 2020 | |
Edges getting pixelated | 0 | 608 | October 5, 2021 | |
Smooth shading results in weird edges? | 10 | 3776 | February 23, 2020 |