Search Issue Tracker
Duplicate
Votes
0
Found in
2019.1.8f1
2019.3
Issue ID
1170325
Regression
No
Texture2D.LoadImage returns true when it can not encode given data
To reproduce:
1. Create a new project
2. Create C# script
3. write
var tex = new Texture2D(32, 32);
var result = tex.LoadImage(System.Text.Encoding.ASCII.GetBytes(
"dfaw0ehfo0i23qnf2q3f9032qh90r2q30fh3092qhf0329qh092q3rj902q3h90f32qh9r03u902q3dj0923qhf90230qh09d32hq9032hq0932qh3r90q2"));
Debug.Log("Result is " + result);
4. Attach the script to game object
5. Press Play
Actual: Texture2D.LoadImage is returning true even when it can't decode the given data
Expected result: Texture2D.LoadImage should return false when can't decode the given data
Reproduced with: 2017.4.31f1; 2018.4.6f1;2019.1.14f1;2019.2.1f1; 2019.3.0a11
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
- Can’t delete gradient keys with Mac keyboard or context menu options
- Editor freezes for a few minutes when closing or switching a VFX window that was opened in a previous project
- UI Overlaps when switching Render Pipeline Asset for different Quality Levels in Quality Project Settings
- Ray Tracing Shader link to the documentation isn’t working
- Warning "BatchRendererGroups currently don't support override shaders" is spammed in Play mode when using H-Trace WSGI with BatchRenderGroups
This is a duplicate of issue #1008863