Search Issue Tracker

Postponed means that the issue was either a feature request or something that requires major refactoring on our side. Since that makes the issue not actionable in the close future we choose to close it as Postponed and add it on our internal roadmaps and technical debt pages instead.

Postponed

Votes

0

Found in

2019.4

2020.3

2020.3.23f1

2021.2

2022.1

Issue ID

1389120

Regression

No

Graphics.CopyTexture() fails in Build when copying a source texture with Read/Write disabled

Graphics Device Features

-

Reproduction steps:
1. Open the user's attached project ("MinimalTest.zip")
2. Enter Play mode
3. Build and Run the project

Expected result: Canvas text is the same in Editor and Build
Actual result: Text is different: "23 (Copy Non Readable)" in Editor and "20.09804 (Copy Non Readable)" in Build

Reproducible with: 2019.4.34f1, 2020.3.25f1, 2021.2.7f1, 2022.1.0b2

Note: Commenting out line 17 of test.cs will produce the result of the Build in Editor: "20.09804 (Copy Non Readable)"

  1. Resolution Note (2022.2.X):

    The inconsistent behavior between the editor and player is a result of Textures requiring the CPU-addressable copy of the texture's pixel data in the editor (regardless of the value of Texture.isReadable) in order to support author-time tooling. We are planning to add new APIs specifically for editor scripts to disambiguate this. We can update the Unity documentation to make this more clear in the meantime until the new APIs are added.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.