A signed distance field texture is a technique where you store the distance from a pixel to the surface of a shape within the color information for that pixel, allowing almost vector graphics quality rendering using textures (http://blog.demofox.org/2014/06/30/distance-field-textures/)
When reading the texture data in a shader, you get values between 0 and 1, which is meant to map between -1 and 1.
The distance data is essentially "normalized" when creating the shader, which means that instead of storing a true positive or negative distance value in the texture, you instead multiply (divide) the real distance by some constant value, clamp it to be between 0 and 1 and then store that distance value.
That constant value essentially controls the width in pixels of the "gradient" band, where the surface of the shape goes from 0 to 1 (-1 to 1).
Is there an optimal value for this based on the output texture resolution or anything else? I always use trial and error until it looks right but feel there must be a better way.
Also, is there a way to choose an optimal output texture size? Or should you just always use a texture size smaller than the size you intend to render it at?