Search Issue Tracker
Won't Fix
Votes
0
Found in
2018.2.11f1
Issue ID
1093051
Regression
No
TextureImporterType.Sprite does not create a usable sprite when called in OnPostprocessTexture
How to reproduce:
1. Open the attached Unity project
2. Drag an PNG or JPEG file (for example an image from your own pictures folder) an onto Assets/LevelMenu folder
Expected result: The image is being imported as a Sprite and is ready to use
Actual result: The image is imported as a Sprite but it can't be used when dragged onto a Sprite Component or any other Texture Component, and is lacking the arrow next to it that can be clicked, to display the image
Reproduced in: 2017.4.15f1 2018.1.9f2, 2018.2.16f1, 2018.3.0b10, 2019.1.0a9
Note: The user followed the steps In the video which Unity has released, where it works as intended. there is no issue if called "void OnPreprocessTexture()" or if in "OnPostprocessTexture()" you use the call "assetImporter.SaveAndReimport();" once after image it was imported.
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
- Editor crashes on StoredGraphicsBuffer::GetGfxBufferID when VFX Graph property is modified during Play Mode and Application.targetFrameRate is used to limit FPS
- Crash on NVAPI_Thunk when changing Player resolution while HDR display is used and Direct3D12 is set as the graphics API
- Only one out of multiple cameras is shown in the Play Mode while HDR display is used and Direct3D12 is set as the graphics API
- The "Paste Component as New" option is incorrectly displayed as active despite the action being prohibited
- "TLS Allocator ALLOC_TEMP_TLS" errors are thrown when unsuccessfully importing an FBX file
Resolution Note (2019.1.X):
The problem reported is actually caused by a misuse of the OnPostprocessTexture call.