Class Light
Base class for all light types.
public abstract class Light : IIdentifier, ISerialization
- Inheritance
-
Light
- Implements
- Derived
- Inherited Members
Properties
Color
The color of the light.
public virtual Vector4 Color { get; set; }
Property Value
HasShadowMap
Indicates whether the light has a shadow map.
public abstract bool HasShadowMap { get; }
Property Value
ID
Gets the unique identifier for this instance.
public Guid ID { get; }
Property Value
Intensity
The intensity of the light.
public virtual float Intensity { get; set; }
Property Value
Name
Gets or sets the name associated with the object.
public string Name { get; set; }
Property Value
Position
The position of the light.
public virtual Vector3 Position { get; set; }
Property Value
ShadowMap
The range of the light.
public DepthOnlyRenderTarget ShadowMap { get; set; }
Property Value
ShadowMapSize
The size of the shadow map in pixels.
public Vector2i ShadowMapSize { get; set; }
Property Value
Methods
Deserialize(JObject, SerializationContext, Func<JObject, bool>)
Populates the current object with values from the specified JSON object.
public virtual void Deserialize(JObject obj, SerializationContext serializationContext, Func<JObject, bool> callback = null)
Parameters
objJObjectserializationContextSerializationContextcallbackFunc<JObject, bool>
Dispose(IRenderDevice)
Disposes the light resources associated with the renderer.
public abstract void Dispose(IRenderDevice renderer)
Parameters
rendererIRenderDevice
Init(IRenderDevice)
Initializes the light with the given renderer.
public abstract void Init(IRenderDevice renderer)
Parameters
rendererIRenderDevice
Serialize(JsonWriter, SerializationContext, Action<JsonWriter>)
Serializes the current object to a Newtonsoft.Json.Linq.JObject using the specified serialization context.
public virtual void Serialize(JsonWriter writer, SerializationContext serializationContext, Action<JsonWriter> callback = null)
Parameters
writerJsonWriterserializationContextSerializationContextThe context that provides information and settings required for serialization.
callbackAction<JsonWriter>