Axiom.SceneManagers.Bsp.TextureLight.CalculateForDirectionalLight C# (CSharp) Method

CalculateForDirectionalLight() protected method

protected CalculateForDirectionalLight ( Plane plane, Vector3 vertices, Vector2 &texCoors, ColorEx &colors ) : bool
plane Axiom.Math.Plane
vertices Vector3
texCoors Vector2
colors Axiom.Core.ColorEx
return bool
		protected bool CalculateForDirectionalLight( Plane plane, Vector3[] vertices, out Vector2[] texCoors, out ColorEx[] colors )
		{
			texCoors = new Vector2[ vertices.Length ];
			colors = new ColorEx[ vertices.Length ];

			float angle = Utility.Abs( plane.Normal.Dot( this.DerivedDirection ) );

			ColorEx lightCol = new ColorEx( textureColor.a * angle,
				textureColor.r, textureColor.g, textureColor.b );

			for ( int i = 0; i < vertices.Length; i++ )
			{
				colors[ i ] = lightCol;
			}

			return true;
		}