Skip to content

Commit 3b8bf31

Browse files
emilybrown1sebastienlagarde
authored andcommitted
Update Light Anchor page (#6955)
* Updated Light Anchor to match Core RP page * added light anchor page to ToC * Update light-anchor.md
1 parent b3d3327 commit 3b8bf31

File tree

2 files changed

+32
-11
lines changed

2 files changed

+32
-11
lines changed

com.unity.render-pipelines.high-definition/Documentation~/TableOfContents.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@
132132
* [Planar Reflection Probe](Planar-Reflection-Probe.md)
133133
* [Reflection Proxy Volume](Reflection-Proxy-Volume.md)
134134
* [Light](Light-Component.md)
135+
* [Light Anchor](light-anchor.md)
135136
* [Environment Lighting](Environment-Lighting.md)
136137
* [Clouds in HDRP](clouds-in-hdrp.md)
137138
* [Atmospheric Scattering](Atmospheric-Scattering.md)
Lines changed: 31 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,41 @@
1-
# Light Anchor
1+
## Light Anchor
22

3-
![](Images/LightAnchor0.png)
3+
The Light Anchor can help to place light sources around subjects, in relation to a Camera and an anchor point. It's particularly effective for cinematic lighting, which often requires multiple light sources orbiting a subject.
4+
5+
## Using the Light Anchor Component
6+
7+
To add a Light Anchor component to a GameObject in your Scene:
8+
9+
1. Select a Light GameObject in the hierarchy to open its Inspector window.
10+
2. Go to **Add Component** > **Rendering** > **Light Anchor**
11+
12+
By default, the Anchor's position is the same as the position of the GameObject the Light Anchor Component is attached to.
13+
14+
**Note**: To use the Light Anchor, you must set the Tag of at least one Camera to "MainCamera".
415

5-
You can use a Light Anchor to light a scene in rendered Camera Space. You can also make the Light move and rotate to match your lighting set up. To do this, attach a [Transform](https://docs.unity3d.com/ScriptReference/Transform.html) to the Light Anchor in the **Anchor Position Override** field.
16+
Use the **Orbit** and **Elevation** to control the orientation of the light, in degrees, relative to the main Camera's and Anchor's positions. If the Light has a Cookie or an IES Profile, use the **Roll** to change their orientation. Use the **Distance** to control how far from the anchor, in meters, you want to place the Light.
17+
18+
You can use the **Anchor Position Override** to provide a GameObject’s [Transform](https://docs.unity3d.com/ScriptReference/Transform.html) as an anchor point for the Light. This is useful if you want the Light to follow a specific GameObject in the Scene.
619

720
![](Images/LightAnchorAnimation.gif)
821

9-
**Note:** The reference Camera that adjusts the light rotation in the above example is the Main Camera. This means that the Common presets can create a different result in the Scene View if your view is not aligned with the Main Camera.
22+
**Note**: The above example uses the Main Camera as the reference Camera that adjusts the light rotation. The Common presets might create a different result in the Scene View if your view isn't aligned with the Main Camera.
23+
24+
You can set a **Position Offset** for this custom Anchor. This is useful if the Transform position of the custom Anchor isn't centered appropriately for the light to orbit correctly around the custom Anchor.
25+
26+
![](Images/LightAnchor0.png)
27+
28+
29+
The Light Anchor component also includes a list of **Presets** that you can use to set the Light's orientation relative to the main Camera.
1030

1131
## Properties
1232

1333
| **Property** | **Description** |
1434
| --------------- | ------------------------------------------------------------ |
15-
| Orbit | Use the left icon to control the Orbit of the light. This tool becomes green when you move the icon. |
16-
| Elevation | Use the middle icon to control the Elevation of the light. This tool becomes blue when you move the icon. |
17-
| Roll | Use the right icon to control the Rollof the light. This tool becomes gray when you move the icon. This is especially useful if the light has an IES or a Cookie. |
18-
| Distance | Controls the distance between the light and its anchor in world space. |
19-
| Up Direction | Defines the space of the up direction of the anchor. When this value is set to Local, the Up Direction is relative to the camera. |
20-
| Anchor Position Override | Allows you to use a GameObject's [Transform](https://docs.unity3d.com/ScriptReference/Transform.html) as anchor position instead of the LightAnchor's Transform. When the Transform of the GameObject you assigned to this property changes, the Light Anchor's Transform also changes. |
21-
| Common | Assigns a preset to the light component based on the behaviour of studio lights. |
35+
| **Orbit** | Use the left icon to control the Orbit of the light. This tool becomes green when you move the icon. |
36+
| **Elevation** | Use the middle icon to control the Elevation of the light. This tool becomes blue when you move the icon. |
37+
| **Roll** | Use the right icon to control the Roll of the light. This tool becomes gray when you move the icon. This is useful if the light has an IES or a Cookie. |
38+
| **Distance** | Controls the distance between the light and its anchor in world space. |
39+
| **Up Direction** | Defines the space of the up direction of the anchor. When you set this value to Local, the Up Direction is relative to the Camera. |
40+
| **Anchor Position Override** | Allows you to use a GameObject's [Transform](https://docs.unity3d.com/ScriptReference/Transform.html) as anchor position instead of the LightAnchor's Transform. When the Transform of the GameObject you assigned to this property changes, the Light Anchor's Transform also changes. |
41+
| **Common** | Assigns a preset to the light component based on the behavior of studio lights. |

0 commit comments

Comments
 (0)