コード例 #1
0
ファイル: Demo.cs プロジェクト: gitter-badger/Flare.Framework
 protected void OnLoad(object sender, EventArgs e)
 {
     spriteBatch = new SpriteBatch();
     texture = new Texture(new Bitmap(@"Content/test.png"));
     sprite = new Sprite(texture);
     arial = new BitmapFont("Content/arial_test");
     text = new Text(arial, "The quick brown fox \njumps over the lazy dog.", new Vector2(0, 256), Color.Black);
     fpsFont = new BitmapFont(@"Content/fps_font");
     fpsCounter = new ClockDisplay(Game.Clock, fpsFont, Vector2.Zero, Color.Black); // White is also default
     camera = Camera.CreateOrthographic(Game.ClientSize.Width, Game.ClientSize.Height, -1, 1);
 }
コード例 #2
0
 public static void Draw(this SpriteBatch spriteBatch, ClockDisplay display)
 {
     display.Draw(spriteBatch);
 }