You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it might be good to have a very robust test case for metrics that covers this module and also mdsf-bmfont. It seems like msdf-bmfont had some issues with alignment (Experience-Monks#11) which means all fonts exported with it may be wrong (and perhaps also msdf-bmfont-xml, since it seemed like I was getting similar alignments there).
Keep up the awesome work in this module, by the way! 😄
The text was updated successfully, but these errors were encountered:
Thanks for mention it. There are several commits ahead of Jam3/msdf-bmfont related on this issue like 437b2cb and 4a76865 .
I'm no expert at font metrics things, so if you found any metrics problems, please let me know, I'll try to fix.
I also experienced metrics issues. When rendering the text, the bottom of the letters are getting below the line (for example the bottom of the 'g' character is cut). In my font example the lineHeight was reporting 33.6. It was looking right with a value of approximately 37. Using opentype.js.org, I checked the font properties:
The actual code uses method 1. By observation, without really understanding the font metrics, I would say that taking the 3 properties from the "Horizontal Header table" instead of "OS/2 and Windows Metrics table" fixes the issue.
My test case was with the font Roboto-Regular.ttf, size 32.
Hey there,
I think it might be good to have a very robust test case for metrics that covers this module and also mdsf-bmfont. It seems like msdf-bmfont had some issues with alignment (Experience-Monks#11) which means all fonts exported with it may be wrong (and perhaps also msdf-bmfont-xml, since it seemed like I was getting similar alignments there).
Keep up the awesome work in this module, by the way! 😄
The text was updated successfully, but these errors were encountered: