Font artifacts and over all weirdness

Hello

If you look at the picture you can see the in editor does not look like the font. I have changed the intensity but that does not seem to work. tried with opentype and truetype and both look the same

Unfortunately, this is a side effects of distance field rendering approach that we are using. More details here: https://www.google.com/amp/s/lambdacube3d.wordpress.com/2014/11/12/playing-around-with-font-rendering/amp/

ok so there is nothing that can be done? Didn’t know if there was a way to increase the resolution or something like that

Increasing the texture size may help? I don’t know if that’s an option in our editor at the moment. I will have to defer to our graphic developers on this one to be honest. @mvaligursky or @slimbuck, Any ideas on how we could get pixel fonts to look better?

Hey @kdarius when I first saw your picture I thought this was a matter of adjusting the font’s intensity.

Just throwing this out there, if you press “process font” in the font setting panel it will actually reset the intensity value. I don’t know if that helps or not, but I just ran into that myself about an hour ago.

I suspect what you see is a texture converted to Signed Distance Field as mentioned. When the text using this font is rendered, the math in the shader uses this information to draw soft edges / drop shadows and similar, the texture is not rendered directly. Have you tried using this font in say UI rendering? That should render nicely.

@RipcordDev i tried intensity but that did not work?

@mvaligursky sorry when you say UI rendering what do you mean? the Text is on an element that is on a 2d screen

would you be able to create a tiny project with a repro for us to look at please?

It’s a corporate project but since u are part of the playcanvas team I can give u access for a little bit or send u the font

@mvaligursky and luck figuring out the issue?

@kdarius @mvaligursky - PlayCanvas uses a multi-channel SDF tool called msdfgen (https://github.com/Chlumsky/msdfgen) to create font assets from truetype/opentype files - and it seems msdfgen is not handling this font well - I did a search of existing msdfgen issues and the problem could be related to an existing open msdfgen issue: https://github.com/Chlumsky/msdfgen/issues/80 - which unfortunately doesn’t seem to have a trivial fix.