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
- var VisionOSEDRHeadromm has a comma instead of a dot when building with Metal Rendering App Mode and local OS localization is set to German
- IAP Catalog remove product “x” and add product “+” buttons are not consistent with other remove and add buttons in the Editor
- Performance issues in Play Mode when quickly hovering the mouse cursor over Hierarchy GameObjects
- Frame Debugger displays incorrect output when FidelityFX Super Resolution or Spatial-Temporal Upscaler is used with Temporal Anti-aliasing or Subpixel Morphological Anti-aliasing
- The layout system is failing to correctly calculate or apply the height of the Japanese fallback font when the primary English font's metrics are used
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.