Search Issue Tracker
By Design
By Design in 2023.2.X
Votes
0
Found in
2021.3.22f1
2022.2.13f1
2023.1.0b10
2023.2.0a7
Issue ID
UUM-32803
Regression
Yes
The overlay camera does not capture RenderTexture when rendering to screen
Reproduction steps:
1. Open the attached project “CameraNoImage“
2. Enter The Play Mode
3. Select “UI“ GameObject in the Hierarchy window
4. Click on the “Capture“ checkbox of “Capture Camera Render Texture“ in the Inspector window
Expected result: Game view is captured and is displayed on the “RawImage“ GameObject
Actual result: Nothing is displayed
Reproducible with: 2021.2.0a16, 2021.3.22f1, 2022.2.13f1, 2023.1.0b10, 2023.2.0a7
Not reproducible with: 2020.3.46f1, 2021.2.0a15
Reproducible on: Windows10
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
- Line Brush blue outline appears at incorrect position when painting start of line in Tile Palette
- [URP] All materials render black when building via batchmode or without rendering Scene/Game view in Editor if Decal renderer Technique is set to "Automatic"
- Player Tags list shows extra blank space behind the scrollbar in the "Player Tags" settings window
- Edit Angular Limits gizmo handles are small and easy to miss-click in the Scene view
- Duplicate Player Tag save fails silently with no error or validation message
Resolution Note:
Overlay cameras do not write to target textures, that only applies to base cameras, the overlay cameras then write on top of the base camera target texture, so rendering the UI to the overlay camera and expecting to access the frame results by referencing the overlay camera target texture is wrong usage. This used to work before 21.3 because it was a bug/undefined behaviour, which was fixed in that version.
The correct way to make this scene work as intended is to:
- change the UI camera to base camera
- change the priority to 1 so it is rendered after the base camera
the Capture script should now work correctly
Resolution Note (2023.2.X):
Overlay cameras do not write to target textures, that only applies to base cameras, the overlay cameras then write on top of the base camera target texture, so rendering the UI to the overlay camera and expecting to access the frame results by referencing the overlay camera target texture is wrong usage. This used to work before 21.3 because it was a bug/undefined behaviour, which was fixed in that version.
The correct way to make this scene work as intended is to:
- change the UI camera to base camera
- change the priority to 1 so it is rendered after the base camera
the Capture script should now work correctly