Light Probe
Updated
Lights what is inside its box with probes, and shadows, baked by the Light Probe Solver.
- Type
comp-light-probe- Script class
LightProbeComponent- Per entity
- One
- Version
- 1.0.0
Read about it in Light probes: what it does, how to use it from a script, and examples.
Properties
Section titled “Properties”The props the runtime declares for this component, with their defaults and accepted ranges.
| Prop | Default | Range |
|---|---|---|
lighting |
0 ≤ x ≤ 1 |
|
shadowQuality |
0 ≤ x ≤ 1 |
Live example
Section titled “Live example”Run it in the browser, read its scripts, and download it as an XR Creator project.
Live example
A safety fill light for unbaked roomsA kitchen whose light probe volume was never baked gets its hemisphere fill light raised so it is not left dark: a Light Probe checked by a Behavior script at startup.
The volume is not baked, so the fill light is raised to 0.7. Drag to orbit the camera, scroll to zoom.
From a script
Section titled “From a script”#pragma lifecycle(startup)
function startup() { const component = self.parent.getComponent(LightProbeComponent); if (component) log(component.props);}