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
- “Remove Unused Overrides” available on not loaded Scene and throws “ArgumentException: The scene is not loaded” warning
- Adaptive Probe Volume occlusion edge is calculated incorrectly when viewing probes near geometry edges
- Sampling a texture using an HLSL file throws shader errors and the code does not compile
- "Graphics.CopyTexture called with null source texture" error when Base Camera of an Overlay Camera is removed with DX11 Graphics API and Compatibility Mode enabled
- WebGL sends wrong value with large numbers when SendMessage function is used
Resolution Note (fix version 12.0.0):
Fix for this issue available on Unity 2021.2.0b14 and above