Search Issue Tracker
Fixed in 12.0.0
Votes
0
Found in [Package]
11.0.0
Issue ID
1320535
Regression
No
[2D][URP] Increasing Freeform Light 2D Falloff greater than 53 causes errors in console
[2D][URP] Increasing Freeform Light 2D Falloff greater than 53 causes errors in console
Repro steps:
1. Open SampleScene in attached "2DLight_Falloff_Bug_2" project
2. Observe Light 2D in scene, increase its Falloff in inspector to any value greater than 53, observe IndexOutOfRange exception in console
IndexOutOfRangeException: Index 1024 is out of range of '1024' Length.
Unity.Collections.NativeArray`1[T].FailOutOfRangeError (System.Int32 index) (at <382795dbdc064c2c97e30b4fbf6ba703>:0)
Unity.Collections.NativeArray`1[T].CheckElementWriteAccess (System.Int32 index) (at <382795dbdc064c2c97e30b4fbf6ba703>:0)
Unity.Collections.NativeArray`1[T].set_Item (System.Int32 index, T value) (at <382795dbdc064c2c97e30b4fbf6ba703>:0)
UnityEngine.Experimental.Rendering.Universal.LightUtility.GenerateShapeMesh (UnityEngine.Experimental.Rendering.Universal.Light2D light, UnityEngine.Vector3[] shapePath, System.Single falloffDistance) (at Library/PackageCache/com.unity.render-pipelines.universal@12.0.0/Runtime/2D/LightUtility.cs:334)
UnityEngine.Experimental.Rendering.Universal.Light2D.UpdateMesh (System.Boolean forceUpdate) (at Library/PackageCache/com.unity.render-pipelines.universal@12.0.0/Runtime/2D/Light2D.cs:244)
UnityEngine.Experimental.Rendering.Universal.Light2D.LateUpdate () (at Library/PackageCache/com.unity.render-pipelines.universal@12.0.0/Runtime/2D/Light2D.cs:318)
Expected result: Falloff increases gracefully without errors in console
Actual result: Errors in console if Falloff increases above 53
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Unity Hub Module icons wrap poorly when they occupy two rows
- "Add new query block" (+) button has no highlight when navigated with the keyboard
- WebGPU errors when CoreCopy shader is used to copy an MSAA texture
- Unity Cloud icon does not appear next to project and does not connect correctly when the project is created with Cloud but closed right after creation
- ScrollerSlider in the Scroller Control is still using UXMLTraits
Resolution Note (fix version 12.0.0):
Fix for this issue available on Unity 2021.2.0b14 and above