Kav/Lights/PointLight.cs

25 lines
566 B
C#
Raw Normal View History

2020-08-04 09:32:02 +00:00
using Microsoft.Xna.Framework;
namespace Kav
{
2020-08-07 08:12:46 +00:00
public struct PointLight
2020-08-04 09:32:02 +00:00
{
2020-12-10 00:10:53 +00:00
public static double ATTENUATION_EPSILON = 0.1;
2020-08-07 08:12:46 +00:00
public Vector3 Position { get; }
public Color Color { get; }
2020-12-10 00:28:40 +00:00
public float Radius { get; }
2020-08-04 09:32:02 +00:00
2020-12-10 00:10:53 +00:00
public BoundingSphere BoundingSphere { get; }
2020-12-10 00:28:40 +00:00
public PointLight(Vector3 position, Color color, float radius)
2020-08-04 09:32:02 +00:00
{
Position = position;
Color = color;
2020-12-10 00:28:40 +00:00
Radius = radius;
2020-12-10 00:10:53 +00:00
2020-12-10 00:28:40 +00:00
BoundingSphere = new BoundingSphere(position, Radius);
2020-08-04 09:32:02 +00:00
}
}
}