Fusion.Engine.Graphics.RenderSystem.Initialize C# (CSharp) Method

Initialize() public method

Intializes graphics engine.
public Initialize ( ) : void
return void
		public override void Initialize ()
		{
			whiteTexture	=	new DynamicTexture( this, 4,4, typeof(Color), false, false );
			whiteTexture.SetData( Enumerable.Range(0,16).Select( i => Color.White ).ToArray() );
			
			grayTexture		=	new DynamicTexture( this, 4,4, typeof(Color), false, false );
			grayTexture.SetData( Enumerable.Range(0,16).Select( i => Color.Gray ).ToArray() );

			blackTexture	=	new DynamicTexture( this, 4,4, typeof(Color), false, false );
			blackTexture.SetData( Enumerable.Range(0,16).Select( i => Color.Black ).ToArray() );

			flatNormalMap	=	new DynamicTexture( this, 4,4, typeof(Color), false, false );
			flatNormalMap.SetData( Enumerable.Range(0,16).Select( i => new Color(127,127,255,127) ).ToArray() );

			var baseIllum = new BaseIllum();
			defaultMaterial	=	baseIllum.CreateMaterialInstance(this, Game.Content);

			//	add default render world
			renderWorld	=	new RenderWorld(Game, Width, Height);
			AddLayer( renderWorld );
		}