Posted January 20, 20187 yr For performance reasons I have code that renders text elements using drawString() to a dynamic texture. The texture is updated whenever resources are reloaded (i.e. a resource pack is added/removed). Right now I have a hard coded 64x64 texels for each of the elements stitched into this texture. The code works with the default Minecraft font as well as texture packs that have "64x" support. My concern, though, is the amount of resources being used based on the default assumption of 64x64 texels. What I would like to do is pick the texel size for each element based on whether a "16x", "32x", "64x" font is being used. Is there a method somewhere or a calculation I can perform that would give me this answer?
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.