Search Issue Tracker
By Design
Votes
0
Found in
6000.0.58f1
6000.1.16f1
6000.2.6f1
6000.3.0b3
Issue ID
UUM-119462
Regression
No
InvalidOperationException when using Game Camera Preview in Scene window with a custom RenderGraph pass
Reproduction steps:
1. Open the attached “IN-116254_TestPass.zip“ archived project
2. Enable the ‘Cameras’ option in the Overlay Menu, which is located in the lower-left corner of the Scene View
3. Observe the Game Camera Preview and the Console
Expected result: No errors in the Console. The custom render pass executes correctly when previewing the Game Camera in the Scene window
Actual result: Multiple different errors are present in the Console. The custom render pass fails in the Game Camera Preview
Reproducible with: 6000.0.58f1, 6000.1.16f1, 6000.2.6f1, 6000.3.0b3
Reproducible on: M1 Max MacOS 15.5 (Tested by CQA)
Not reproducible on: No other environment tested
Errors:
”Render Graph Execution error”
”Exception: Mismatch in Fragment dimensions”
”InvalidOperationException: Trying to use a texture (_CameraTargetAttachment) that was already released or not yet created. Make sure you declare it for reading in your pass or you don't read it before it's been written to at least once.”
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
- "Shader warning in 'Hidden/Light2D': implicit truncation of vector type" is thrown when building Universal 2D template
- AI Assistant breaks compilation of packages using System.Runtime.CompilerServices.Unsafe via auto-referencing
- Unity Hub checks the "Documentation" module by default on the 6.4 and 6.5 streams despite that it was unchecked with the previous installs
- Shortcut that toggles between Dopesheet and Curves Views in the Animation Window's Timeline is mislabed
- Property List Items Overlap onto the Property List's top edge when scrolling through a long Property List
Resolution Note:
The issue here is using Screen.Width/Screen.Height, which is the current window resolution, not the resolution of the main color target. Instead, use either UniversalCameraData.cameraTargetDescriptor to get the color target resolution. See e.g https://docs.unity3d.com/6000.3/Documentation/Manual/urp/render-graph-write-render-pass.html
Alternatively, use GetTextureDesc on the active color target (https://docs.unity3d.com/Packages/com.unity.render-pipelines.core@15.0/api/UnityEngine.Experimental.Rendering.RenderGraphModule.RenderGraph.GetTextureDesc.html)