diff --git a/com.unity.render-pipelines.core/Runtime/Common/DynamicResolutionHandler.cs b/com.unity.render-pipelines.core/Runtime/Common/DynamicResolutionHandler.cs index 7ae4dc7cca9..3746fe009a6 100644 --- a/com.unity.render-pipelines.core/Runtime/Common/DynamicResolutionHandler.cs +++ b/com.unity.render-pipelines.core/Runtime/Common/DynamicResolutionHandler.cs @@ -159,7 +159,8 @@ public void Update(GlobalDynamicResolutionSettings settings, Action OnResolution ScalableBufferManager.ResizeBuffers(m_CurrentFraction, m_CurrentFraction); } - OnResolutionChange(); + if(OnResolutionChange != null) + OnResolutionChange(); } else { @@ -169,7 +170,8 @@ public void Update(GlobalDynamicResolutionSettings settings, Action OnResolution if(ScalableBufferManager.widthScaleFactor != m_PrevHWScaleWidth || ScalableBufferManager.heightScaleFactor != m_PrevHWScaleHeight) { - OnResolutionChange(); + if (OnResolutionChange != null) + OnResolutionChange(); } } } diff --git a/com.unity.render-pipelines.high-definition/CHANGELOG.md b/com.unity.render-pipelines.high-definition/CHANGELOG.md index 312f5878fd9..bd17988f4e7 100644 --- a/com.unity.render-pipelines.high-definition/CHANGELOG.md +++ b/com.unity.render-pipelines.high-definition/CHANGELOG.md @@ -750,6 +750,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Fixed a missing dependecy for choosing to evaluate transparent SSR. - Fixed issue that failed compilation when XR is disabled. - Fixed a compilation error in the IES code. +- Fixed issue with dynamic resolution handler when no OnResolutionChange callback is specified. ### Changed - Improve MIP selection for decals on Transparents