Class LightAnchor
Represents camera-space light controls around a virtual pivot point.
Inherited Members
Namespace: UnityEngine
Assembly: Unity.RenderPipelines.Core.Runtime.dll
Syntax
[AddComponentMenu("Rendering/Light Anchor")]
[ExecuteInEditMode]
[DisallowMultipleComponent]
[CoreRPHelpURL("View-Lighting-Tool", "com.unity.render-pipelines.core")]
public class LightAnchor : MonoBehaviour
Properties
Name | Description |
---|---|
anchorPosition | The position of the light's anchor point. |
anchorPositionOffset | Offset relative to the position of the anchor position override transform in object space. |
anchorPositionOverride | Overrides the pivot of used to compute the light position. This is useful to track an existing object in the scene. The transform of the light will be automatically updated by the Update() method of the LightAnchor. |
distance | The distance from the light's anchor point. |
frameSpace | Indicates whether the up vector should be in world or camera space. |
pitch | The pitch relative to the horizon or camera depending on value of m_Space. |
roll | The camera-relative roll. |
yaw | The camera-relative yaw. |
Methods
Name | Description |
---|---|
NormalizeAngleDegree(float) | Normalizes the input angle to be in the range of -180 and 180. |
SynchronizeOnTransform(Camera) | Updates Yaw, Pitch, Roll, and Distance based on the Transform. |
UpdateTransform(Camera, Vector3) | Updates the light's transform with respect to a given camera and anchor point |