public BitmapLabel(BitmapFont font) { if (font == null || font.Loaded == false) throw new NullReferenceException("font"); _font = font; AutoSize = true; }
/// <summary> /// Konstruktor klase World. /// </summary> public World(String scenePath, String sceneFileName, int width, int height) { this.m_model = new AssimpScene(scenePath, sceneFileName); this.m_width = width; this.m_height = height; try { m_camera = new MyCamera(); } catch (Exception) { MessageBox.Show("Neuspesno kreirana instanca klase Camera", "GRESKA", MessageBoxButtons.OK, MessageBoxIcon.Error); } try { m_font = new BitmapFont("Times New Roman", 10, true, false, false, false); } catch (Exception) { MessageBox.Show("Neuspesno kreirana instanca OpenGL fonta", "GRESKA", MessageBoxButtons.OK, MessageBoxIcon.Error); } this.Initialize(); // Korisnicka inicijalizacija OpenGL parametara this.Resize(); // Podesavanje projekcije i viewport-a }