You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Port] [6000.0] UUM-78573: "Bake Probe Volumes" button does not store that lights are baked
https://jira.unity3d.com/browse/UUM-78573
This fix addresses a bug that caused the various buttons for baking only Adaptive Probe Volumes to malfunction - they would update the lights in the scene to act as baked, to avoid double-contribution from realtime lighting, but would do so in a way that wasn't persistent across scene reloads.
The root cause is not properly respecting the Lighting Data Asset (LDA). The baked state of each light is stored in the LDA, _not_ on the lights themselves. Changing only the state on the lights themselves will not make a persistent change, and reloading the scene will reload the old unmodified data. To make the change persistent, we need to modify the LDA.
To fix this, I've taken an approach similar to what we do with reflection probes, which have the same issue:
- When you bake only probe volumes, and the scene has no LDA, we create a new empty LDA, assign it to the scene, and fill in the up-to-date states.
- When you bake only probes volumes, and the scene already has a LDA, we modify this LDA to contain up-to-date states for each light.
I had to add a few pieces of public API to achieve this.
0 commit comments