Skip to content

Commit efa678b

Browse files
Antoine Lelievresebastienlagarde
andauthored
Hdrp/fix/cookie area light update (#828)
* Fixed area light cookie not used when a spot cookie is assigned * Updated changelog Co-authored-by: sebastienlagarde <[email protected]>
1 parent c063303 commit efa678b

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

com.unity.render-pipelines.high-definition/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -662,6 +662,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
662662
- Fix inconsistencies with transparent motion vectors and opaque by allowing camera only transparent motion vectors.
663663
- Fix reflection probe frame settings override
664664
- Fixed certain shadow bias artifacts present in volumetric lighting (case 1231885).
665+
- Fixed area light cookie not updated when switch the light type from a spot that had a cookie.
665666

666667
### Changed
667668
- Improve MIP selection for decals on Transparents

com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1486,7 +1486,8 @@ internal void GetLightData(CommandBuffer cmd, HDCamera hdCamera, HDShadowSetting
14861486
lightData.screenSpaceShadowIndex = (int)LightDefinitions.s_InvalidScreenSpaceShadow;
14871487
lightData.isRayTracedContactShadow = 0.0f;
14881488

1489-
if (lightComponent != null && lightComponent.cookie != null)
1489+
// lightComponent.cookie can't be used for area lights
1490+
if (lightComponent != null && lightComponent.cookie != null && lightType != HDLightType.Area)
14901491
{
14911492
switch (lightType)
14921493
{

0 commit comments

Comments
 (0)