Axiom.Core.Root.Shutdown C# (CSharp) Method

Shutdown() public method

Shuts down the engine and unloads plugins.
public Shutdown ( ) : void
return void
		public void Shutdown()
		{
			//_isIntialized = false;
			LogManager.Instance.Write( "*-*-* Axiom Shutdown Initiated." );

			SceneManagerEnumerator.Instance.ShutdownAll();

			// destroy all auto created GPU programs
			ShadowVolumeExtrudeProgram.Shutdown();

			// ResourceBackGroundPool.Instance.Shutdown();
			ResourceGroupManager.Instance.ShutdownAll();
		}

Usage Example

        protected bool Setup()
        {
            RepositoryClass.Instance.InitializeRepositoryPath();

            // get a reference to the engine singleton
            engine = new Root("", "trace.txt");

            // add event handlers for frame events
            engine.FrameStarted += new FrameEvent(OnFrameStarted);
            engine.FrameEnded += new FrameEvent(OnFrameEnded);

            // allow for setting up resource gathering
            if (!SetupResources())
                return false;

            //show the config dialog and collect options
            if (!ConfigureAxiom())
            {
                // shutting right back down
                engine.Shutdown();

                return false;
            }

            if (!CheckShaderCaps())
            {
                MessageBox.Show("Your graphics card does not support pixel shader 2.0 and vertex shader 2.0, which are required to run this tool.", "Graphics Card Not Supported", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                engine.Shutdown();
                return false;
            }

            ChooseSceneManager();
            CreateCamera();
            CreateViewports();

            // set default mipmap level
            TextureManager.Instance.DefaultNumMipMaps = 5;

            // call the overridden CreateScene method
            CreateScene();

            return true;
        }
All Usage Examples Of Axiom.Core.Root::Shutdown