Search Issue Tracker
Won't Fix
Votes
4
Found in
5.0.0b14
Issue ID
649909
Regression
No
Unity does not handle corrupted/unsupported images well
To reproduce:
1. Open attached project
2. It contains a few corrupted pngs (they are still displayable by Windows Image viewer)
3. Notice the errors in console:
Could not create texture from Assets/bd927c8547634cdbdd22af0afe818a9b.png: File could not be read
UnityEditorInternal.InternalEditorUtility:ProjectWindowDrag(HierarchyProperty, Boolean)
UnityEditor.DockArea:OnGUI()
NullReferenceException
UnityEditor.TextureImporterInspector.ApplySettingsToTexture () (at C:/buildslave/unity/build/Editor/Mono/ImportSettings/TextureImporterInspector.cs:1398)
UnityEditor.TextureImporterInspector.ResetValues () (at C:/buildslave/unity/build/Editor/Mono/ImportSettings/TextureImporterInspector.cs:2133)
UnityEditor.AssetImporterInspector.Awake () (at C:/buildslave/unity/build/Editor/Mono/ImportSettings/AssetImporterInspector.cs:104)
Unity doesn't crash and the images are quite corrupted, thus throwing out errors seems like a reasonable way to handle this.
Comments (1)
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
- Tile Palette grid is moved after entering Play Mode
- Tile Palette Edit mode turns off in Play Mode
- The Editor crashes when Generating Font Atlas in the Font Asset Creator with “9999999999” padding and 256x256 Atlas Resolution
- [iOS] An “ArgumentNullException” error is thrown when GetIntroductoryPriceDictionary() method is called
- Memory leak warnings are constantly thrown when Generating Font Atlas in Font Asset Creator with 4096x8192 Atlas Resolution
n1gth
Oct 30, 2015 09:05
In some cases PNGs that work everywhere else do not import in Unity... as it says in the issue it would be better to show a useful warning message rather than a "blank" document file in the assets.