Search Issue Tracker
Fixed
Fixed in 2022.3.51f1
Votes
6
Found in
2023.2.20f1
6000.0.0f1
Issue ID
UUM-70740
Regression
Yes
"SupportsRandomWriteOnRenderTextureFormat()" shows "False" when executed on 2023.2 and 6000.0 streams
Reproduction steps:
1. Open the attached “repro_IN-74679“ project
2. Open the “/Assets/Scenes/SampleScene.unity“ Scene
3. Check the message that appears in the Console
Expected result: “SupportsRandomWriteOnRenderTextureFormat() True“ is displayed
Actual result: “SupportsRandomWriteOnRenderTextureFormat() False” is displayed
Reproducible with: 2023.2.0a6, 2023.2.20f1, 6000.0.0f1
Not reproducible with: 2021.3.37f1, 2022.3.26f1, 2023.2.0.0a5
Reproducible on: macOS Sonoma 14.4.1
Not reproducible on: No other environments tested
Note: Reproducible in Player
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
- Can’t delete gradient keys with Mac keyboard or context menu options
- Editor freezes for a few minutes when closing or switching a VFX window that was opened in a previous project
- UI Overlaps when switching Render Pipeline Asset for different Quality Levels in Quality Project Settings
- Ray Tracing Shader link to the documentation isn’t working
- Warning "BatchRendererGroups currently don't support override shaders" is spammed in Play mode when using H-Trace WSGI with BatchRenderGroups
Resolution Note (fix version 2022.3.51f1):
According to Unity's documentation, the term "random write" denotes if shaders can write into arbitrary locations of a textures. (https://docs.unity3d.com/ScriptReference/RenderTexture-enableRandomWrite.html).
When using D3D11, SupportsRandomWriteOnRenderTextureFormat() should return whether a texture format can be used as a Unordered Access View (UAV). UAVs support *simultaneous* random reads and writes.
In Metal, the term UAV is not used. We need to check the Metal device readWriteTextureSupport. The official Metal documentation of both MTLReadWriteTextureTier.tier1 and MTLReadWriteTextureTier.tier2 does not mention any rg16 format. Therefore the behavior of Unity 6 that returns false for RG16 is correct and this will be fixed on 2022.3.