Beispiel #1
0
 public Font(AssetManager assets, FontDef fontDef)
 {
     _assets    = assets;
     FontDef    = fontDef;
     BitmapFont = new BitmapFont();
     using (Stream stream = assets.OpenStream(fontDef.Path))
     {
         BitmapFont.LoadText(stream);
     }
 }
Beispiel #2
0
 public Font(AssetManager assets, FontDef fontDef, float fillBrightness = 1f, float outlineBrightness = -1f)
 {
     _assets            = assets;
     FontDef            = fontDef;
     _fillBrightness    = fillBrightness;
     _outlineBrightness = outlineBrightness;
     BitmapFont         = new BitmapFont();
     using (Stream stream = assets.OpenStream(fontDef.Path))
     {
         BitmapFont.LoadText(stream);
     }
 }