Manage all Assets with ContentManager

This commit is contained in:
Simon Lübeß
2025-02-16 01:02:41 +01:00
parent 25e1c53a08
commit 49c3e93e08
10 changed files with 57 additions and 33 deletions
@@ -569,11 +569,13 @@ namespace GlitchyEngine.Renderer.Text
if (text.Glyphs.Count == 0)
return;
//Renderer2D.Flush();
// TODO: this doesn't really work with fallback fonts unless we use the same settings for all fonts
float2 unitRange = ((float)text.Font._range) / float2(text.Font._atlas.Width, text.Font._atlas.Height);
_msdfMaterial.SetVariable("UnitRange", unitRange);
List<Texture2D> atlasses = scope .();
for (PreparedGlyph glyph in text.Glyphs)