Axiom.Core.Root.Initialize C# (CSharp) Метод

Initialize() публичный Метод

Initializes the renderer.
This method can only be called after a renderer has been selected with Root.RenderSystem, and it will initialize the selected rendering system ready for use.
public Initialize ( bool autoCreateWindow ) : Axiom.Graphics.RenderWindow
autoCreateWindow bool /// If true, a rendering window will automatically be created. The window will be /// created based on the options currently set on the render system. ///
Результат Axiom.Graphics.RenderWindow
		public RenderWindow Initialize( bool autoCreateWindow )
		{
			return this.Initialize( autoCreateWindow, "Axiom Render Window" );
		}

Same methods

Root::Initialize ( bool autoCreateWindow, string windowTitle ) : Axiom.Graphics.RenderWindow

Usage Example

Пример #1
0
		static void Main(string[] args)
		{
			IConfigurationManager ConfigurationManager = ConfigurationManagerFactory.CreateDefault();
			using (Root _root = new Root("game.log"))
			{
				ConfigurationManager.RestoreConfiguration(_root);
				if (ConfigurationManager.ShowConfigDialog(_root))
				{
					ConfigurationManager.SaveConfiguration(_root);

					using (RenderWindow _renderWindow = _root.Initialize(true, "Illisian.Niva"))
					{

						var game = new Game(_root, _renderWindow);
						WindowEventMonitor.Instance.RegisterListener(_renderWindow, game);
						game.OnLoad();
						game.CreateScene();
						_root.FrameRenderingQueued += game.OnRenderFrame;
						_root.FrameStarted += game.UpdateInput;
						_root.FrameStarted += game.UpdateOverlay;
						_root.FrameEnded += game.OnRenderFrameEnd;
						_root.StartRendering();

						game.OnUnload();
					}
				}

			}
		}
All Usage Examples Of Axiom.Core.Root::Initialize