Search Results for

    Show / Hide Table of Contents

    Class LightWithShadow

    Base class for all light types that can cast dynamic or static shadow. Contains more shared properties for point/spot/directional lights.

    Inheritance
    System.Object
    Object
    SceneObject
    Actor
    Light
    LightWithShadow
    DirectionalLight
    PointLight
    SpotLight
    Implements
    ISerializable
    Inherited Members
    Light.Color
    Light.Brightness
    Light.ViewDistance
    Light.IndirectLightingIntensity
    Light.VolumetricScatteringIntensity
    Light.CastVolumetricShadow
    Actor.SetLayerRecursive(Int32)
    Actor.SetLayerNameRecursive(String)
    Actor.HasTag()
    Actor.HasTag(Tag)
    Actor.HasTag(String)
    Actor.AddTag(Tag)
    Actor.AddTagRecursive(Tag)
    Actor.RemoveTag(Tag)
    Actor.SetParent(Actor, Boolean, Boolean)
    Actor.GetChild(Int32)
    Actor.GetChild(String)
    Actor.GetChild(Type)
    Actor.GetChildren(Type)
    Actor.DestroyChildren(Single)
    Actor.GetScript(Int32)
    Actor.GetScript(Type)
    Actor.GetScripts(Type)
    Actor.AddMovement(Vector3)
    Actor.AddMovement(Vector3, Quaternion)
    Actor.GetWorldToLocalMatrix(Matrix)
    Actor.GetLocalToWorldMatrix(Matrix)
    Actor.OnDebugDraw()
    Actor.OnDebugDrawSelected()
    Actor.GetPrefabRoot()
    Actor.FindActor(String)
    Actor.FindActor(Type, Boolean)
    Actor.FindActor(Type, String)
    Actor.FindActor(Type, Tag, Boolean)
    Actor.FindScript(Type)
    Actor.HasActorInHierarchy(Actor)
    Actor.HasActorInChildren(Actor)
    Actor.IntersectsItself(Ray, Single, Vector3)
    Actor.Intersects(Ray, Single, Vector3)
    Actor.LookAt(Vector3)
    Actor.LookAt(Vector3, Vector3)
    Actor.LookingAt(Vector3)
    Actor.LookingAt(Vector3, Vector3)
    Actor.ToBytes(Actor[])
    Actor.FromBytes(Byte[])
    Actor.FromBytes(Byte[], Dictionary<Guid, Guid>)
    Actor.TryGetSerializedObjectsIds(Byte[])
    Actor.ToJson()
    Actor.FromJson(String)
    Actor.Clone()
    Actor.OnEnable()
    Actor.OnDisable()
    Actor.OnParentChanged()
    Actor.OnTransformChanged()
    Actor.OnActiveChanged()
    Actor.OnActiveInTreeChanged()
    Actor.OnOrderInParentChanged()
    Actor.OnStaticFlagsChanged()
    Actor.OnLayerChanged()
    Actor.OnBeginPlay()
    Actor.OnEndPlay()
    Actor.AddStaticFlags(StaticFlags)
    Actor.RemoveStaticFlags(StaticFlags)
    Actor.SetStaticFlag(StaticFlags, Boolean)
    Actor.HasStaticFlag(StaticFlags)
    Actor.ResetLocalTransform()
    Actor.AddChild(Type)
    Actor.AddChild<T>()
    Actor.GetChild<T>()
    Actor.TryGetChild<T>(T)
    Actor.GetOrAddChild<T>()
    Actor.AddScript(Type)
    Actor.AddScript<T>()
    Actor.GetScript<T>()
    Actor.TryGetScript<T>(T)
    Actor.FindScript<T>()
    Actor.FindActor<T>(Boolean)
    Actor.FindActor<T>(String)
    Actor.FindActor<T>(Tag, Boolean)
    Actor.GetChildren<T>()
    Actor.GetScripts<T>()
    Actor.RotateAround(Vector3, Vector3, Single, Boolean)
    Actor.ToString()
    Actor.Children
    Actor.Tags
    Actor.Layer
    Actor.Name
    Actor.IsActive
    Actor.StaticFlags
    Actor.PerInstanceRandom
    Actor.LocalPosition
    Actor.LocalOrientation
    Actor.LocalScale
    Actor.Sphere
    Actor.Box
    Actor.BoxWithChildren
    Actor.EditorBox
    Actor.EditorBoxChildren
    Actor.HasContentLoaded
    Actor.IsPrefabRoot
    Actor.IsStatic
    Actor.IsTransformStatic
    Actor.WorldToLocalMatrix
    Actor.LocalToWorldMatrix
    SceneObject.SetParent(Actor, Boolean)
    SceneObject.LinkPrefab(Guid, Guid)
    SceneObject.BreakPrefabLink()
    SceneObject.GetNamePath(Char)
    SceneObject.IsDuringPlay
    SceneObject.HasParent
    SceneObject.HasPrefabLink
    SceneObject.PrefabID
    SceneObject.PrefabObjectID
    Object.__unmanagedPtr
    Object.__internalId
    Object.Finalize()
    Object.As<T>()
    Object.NewValue(Type)
    Object.New(String)
    Object.Find<T>(Guid, Boolean)
    Object.Find(Guid, Type, Boolean)
    Object.TryFind<T>(Guid)
    Object.TryFind(Guid, Type)
    Object.Destroy(Object, Single)
    Object.DestroyNow(Object)
    Object.Destroy<T>(T, Single)
    Object.Equals(Object)
    Object.GetUnmanagedPtr(Object)
    Object.GetUnmanagedInterface(Object, Type)
    Object.FromUnmanagedPtr(IntPtr)
    Object.MapObjectID(Guid)
    Object.RemapObjectID(Guid)
    Object.GetHashCode()
    Object.ID
    Object.TypeName
    Namespace: FlaxEngine
    Assembly: FlaxEngine.CSharp.dll
    Syntax
    [Unmanaged]
    public abstract class LightWithShadow : Light, ISerializable

    Constructors

    LightWithShadow()

    Initializes a new instance of the LightWithShadow.

    Declaration
    protected LightWithShadow()

    Properties

    ContactShadowsLength

    The length of the rays for contact shadows computed via the screen-space tracing. Set this to values higher than 0 to enable screen-space shadows rendering for this light. This improves the shadowing details. Actual ray distance is based on the pixel distance from the camera.

    Declaration
    [EditorOrder(99)]
    [EditorDisplay("Shadow", null)]
    [Limit(0F, 0.1F, 0.001F)]
    [Unmanaged]
    public float ContactShadowsLength { get; set; }
    Property Value
    System.Single

    MinRoughness

    The minimum roughness value used to clamp material surface roughness during shading pixel.

    Declaration
    [EditorOrder(40)]
    [EditorDisplay("Light", "Minimum Roughness")]
    [Limit(0F, 1F, 0.01F)]
    [Unmanaged]
    public float MinRoughness { get; set; }
    Property Value
    System.Single

    ShadowsDepthBias

    The depth bias used for shadow map comparison.

    Declaration
    [EditorOrder(95)]
    [EditorDisplay("Shadow", "Depth Bias")]
    [Limit(0F, 10F, 0.0001F)]
    [Unmanaged]
    public float ShadowsDepthBias { get; set; }
    Property Value
    System.Single

    ShadowsDistance

    Shadows casting distance from view.

    Declaration
    [EditorOrder(80)]
    [EditorDisplay("Shadow", "Distance")]
    [Limit(0F, 1000000F, 1F)]
    [Unmanaged]
    public float ShadowsDistance { get; set; }
    Property Value
    System.Single

    ShadowsFadeDistance

    Shadows fade off distance.

    Declaration
    [EditorOrder(90)]
    [EditorDisplay("Shadow", "Fade Distance")]
    [Limit(0F, 10000F, 0.1F)]
    [Unmanaged]
    public float ShadowsFadeDistance { get; set; }
    Property Value
    System.Single

    ShadowsMode

    Describes how a visual element casts shadows.

    Declaration
    [EditorOrder(60)]
    [EditorDisplay("Shadow", "Mode")]
    [Unmanaged]
    public ShadowsCastingMode ShadowsMode { get; set; }
    Property Value
    ShadowsCastingMode

    ShadowsNormalOffsetScale

    A factor specifying the offset to add to the calculated shadow map depth with respect to the surface normal.

    Declaration
    [EditorOrder(96)]
    [EditorDisplay("Shadow", "Normal Offset Scale")]
    [Limit(0F, 100F, 0.1F)]
    [Unmanaged]
    public float ShadowsNormalOffsetScale { get; set; }
    Property Value
    System.Single

    ShadowsResolution

    Defines the resolution of the shadow map texture used to draw objects projection from light-point-of-view. Higher values increase shadow quality at cost of performance.

    Declaration
    [EditorOrder(105)]
    [EditorDisplay("Shadow", "Resolution")]
    [Unmanaged]
    public LightWithShadow.ShadowMapResolution ShadowsResolution { get; set; }
    Property Value
    LightWithShadow.ShadowMapResolution

    ShadowsSharpness

    TheShadows edges sharpness.

    Declaration
    [EditorOrder(70)]
    [EditorDisplay("Shadow", "Sharpness")]
    [Limit(1F, 10F, 0.001F)]
    [Unmanaged]
    public float ShadowsSharpness { get; set; }
    Property Value
    System.Single

    ShadowsStrength

    Dynamic shadows blending strength. Default is 1 for fully opaque shadows, value 0 disables shadows.

    Declaration
    [EditorOrder(75)]
    [EditorDisplay("Shadow", "Strength")]
    [Limit(0F, 1F, 0.001F)]
    [Unmanaged]
    public float ShadowsStrength { get; set; }
    Property Value
    System.Single

    ShadowsUpdateRate

    Frequency of shadow updates. 1 - every frame, 0.5 - every second frame, 0 - on start or change. It's the inverse value of how many frames should happen in-between shadow map updates (eg. inverse of 0.5 is 2 thus shadow will update every 2nd frame).

    Declaration
    [EditorOrder(100)]
    [EditorDisplay("Shadow", "Update Rate")]
    [Limit(0F, 1F, 1F)]
    [Unmanaged]
    public float ShadowsUpdateRate { get; set; }
    Property Value
    System.Single

    ShadowsUpdateRateAtDistance

    Frequency of shadow updates at the maximum distance from the view at which shadows are still rendered. This value is multiplied by ShadowsUpdateRate and allows scaling the update rate in-between the shadow range. For example, if light is near view, it will get normal shadow updates but will reduce this rate when far from view. See ShadowsUpdateRate to learn more.

    Declaration
    [EditorOrder(101)]
    [EditorDisplay("Shadow", "Update Rate At Distance")]
    [Limit(0F, 1F, 1F)]
    [Unmanaged]
    public float ShadowsUpdateRateAtDistance { get; set; }
    Property Value
    System.Single

    Methods

    InvalidateShadow()

    Marks the light shadow to be refreshes during next drawing. Invalidates any cached shadow map and redraws static shadows of the object (if any in use).

    Declaration
    [Unmanaged]
    public void InvalidateShadow()

    Extension Methods

    Extensions.ReflectiveCompare<T>(T, T)
    Extensions.RawClone<T>(T)
    In This Article
    Back to top Copyright © 2012-2024 Wojciech Figat