diff --git a/com.unity.render-pipelines.high-definition/CHANGELOG.md b/com.unity.render-pipelines.high-definition/CHANGELOG.md index 0149f6d0fc7..b8f479617d0 100644 --- a/com.unity.render-pipelines.high-definition/CHANGELOG.md +++ b/com.unity.render-pipelines.high-definition/CHANGELOG.md @@ -25,6 +25,7 @@ The version number for this package has increased due to a version update of a r - Fixed precision issue with the atmospheric fog. - Claryfied doc for the LayeredLit material. - Fixing exceptions in the console when putting the SSGI in low quality mode (render graph). +- Fixed NullRef Exception when decals are in the scene, no asset is set and HDRP wizard is run. ### Changed - Combined occlusion meshes into one to reduce draw calls and state changes with XR single-pass. diff --git a/com.unity.render-pipelines.high-definition/Runtime/Material/Decal/DecalSystem.cs b/com.unity.render-pipelines.high-definition/Runtime/Material/Decal/DecalSystem.cs index 0c941042b8b..3e63e05e06e 100644 --- a/com.unity.render-pipelines.high-definition/Runtime/Material/Decal/DecalSystem.cs +++ b/com.unity.render-pipelines.high-definition/Runtime/Material/Decal/DecalSystem.cs @@ -380,8 +380,6 @@ public void InitializeMaterialValues() if (m_Material == null) return; - bool perChannelMask = HDRenderPipeline.currentAsset.currentPlatformRenderPipelineSettings.decalSettings.perChannelMask; - // TODO: this test is ambiguous, it should say, I am decal or not. // We should have 2 function: I am decal or not and I am a SG or not... m_IsHDRenderPipelineDecal = IsHDRenderPipelineDecal(m_Material); @@ -694,7 +692,6 @@ public void CreateDrawData() Vector3 cameraPos = instance.CurrentCamera.transform.position; var camera = instance.CurrentCamera; Matrix4x4 worldToView = HDRenderPipeline.WorldToCamera(camera); - bool perChannelMask = instance.perChannelMask; int cullingMask = camera.cullingMask; ulong sceneCullingMask = HDUtils.GetSceneCullingMaskFromCamera(camera);