|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.DirectX;
using Microsoft.DirectX.Direct3D;
namespace MdxScene.Lights
{
public class D3dDirectionalLight : D3dLight
{
public D3dDirectionalLight()
{
XDirection = 1;
YDirection = -1;
ZDirection = -1;
}
#region D3dLight implementation
protected override void SetSpecificLightValues(Device d3dDevice)
{
d3dDevice.Lights[Index].Type = LightType.Directional;
d3dDevice.Lights[Index].XDirection = XDirection;
d3dDevice.Lights[Index].YDirection = YDirection;
d3dDevice.Lights[Index].ZDirection = ZDirection;
}
#endregion
#region properties
public float XDirection { get; set; }
public float YDirection { get; set; }
public float ZDirection { get; set; }
#endregion
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.