Browse Source

[PPV2] Fix AO on OSX (#7922)

AO no longer requires sparse texture support
master
Nico de Poel 3 years ago
parent
commit
afc5d4896f
  1. 11
      Packages/com.unity.postprocessing@3.2.2/PostProcessing/Runtime/Effects/AmbientOcclusion.cs

11
Packages/com.unity.postprocessing@3.2.2/PostProcessing/Runtime/Effects/AmbientOcclusion.cs

@ -197,16 +197,13 @@ namespace UnityEngine.Rendering.PostProcessing
state &= SystemInfo.supportsComputeShaders state &= SystemInfo.supportsComputeShaders
&& !RuntimeUtilities.isAndroidOpenGL && !RuntimeUtilities.isAndroidOpenGL
#if UNITY_2023_2_OR_NEWER #if UNITY_2023_2_OR_NEWER
&& SystemInfo.IsFormatSupported(GraphicsFormat.R32_SFloat, GraphicsFormatUsage.Render | GraphicsFormatUsage.Sparse)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R16_SFloat, GraphicsFormatUsage.Render | GraphicsFormatUsage.Sparse)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R8_UNorm, GraphicsFormatUsage.Render | GraphicsFormatUsage.Sparse);
&& SystemInfo.IsFormatSupported(GraphicsFormat.R32_SFloat, GraphicsFormatUsage.Render)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R16_SFloat, GraphicsFormatUsage.Render)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R8_UNorm, GraphicsFormatUsage.Render);
#else #else
&& SystemInfo.IsFormatSupported(GraphicsFormat.R32_SFloat, FormatUsage.Render) && SystemInfo.IsFormatSupported(GraphicsFormat.R32_SFloat, FormatUsage.Render)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R32_SFloat, FormatUsage.Sparse)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R16_SFloat, FormatUsage.Render) && SystemInfo.IsFormatSupported(GraphicsFormat.R16_SFloat, FormatUsage.Render)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R16_SFloat, FormatUsage.Sparse)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R8_UNorm, FormatUsage.Render)
&& SystemInfo.IsFormatSupported(GraphicsFormat.R8_UNorm, FormatUsage.Sparse);
&& SystemInfo.IsFormatSupported(GraphicsFormat.R8_UNorm, FormatUsage.Render);
#endif #endif
} }

Loading…
Cancel
Save