UpdateTriangleLightFacing() public méthode

Calculate the light facing state of the triangles in this edge list.
This is normally the first stage of calculating a silhouette, ie establishing which tris are facing the light and which are facing away. This state is stored in the 'lightFacing' flag in each Triangle.
public UpdateTriangleLightFacing ( Vector4 lightPos ) : void
lightPos Vector4 /// 4D position of the light in object space, note that /// for directional lights (which have no position), the w component /// is 0 and the x/y/z position are the direction. ///
Résultat void
Exemple #1
0
		/// <summary>
		///		Tells the caster to perform the tasks necessary to update the
		///		edge data's light listing. Can be overridden if the subclass needs
		///		to do additional things.
		/// </summary>
		/// <param name="edgeData">The edge information to update.</param>
		/// <param name="lightPosition">4D vector representing the light, a directional light has w=0.0.</param>
		protected virtual void UpdateEdgeListLightFacing( EdgeData edgeData, Vector4 lightPosition )
		{
			edgeData.UpdateTriangleLightFacing( lightPosition );
		}
 /// <summary>
 ///		Tells the caster to perform the tasks necessary to update the
 ///		edge data's light listing. Can be overridden if the subclass needs
 ///		to do additional things.
 /// </summary>
 /// <param name="edgeData">The edge information to update.</param>
 /// <param name="lightPosition">4D vector representing the light, a directional light has w=0.0.</param>
 protected virtual void UpdateEdgeListLightFacing(EdgeData edgeData, Vector4 lightPosition)
 {
     edgeData.UpdateTriangleLightFacing(lightPosition);
 }