Search Issue Tracker
By Design
Votes
0
Found in
2018.3.0a1
2019.1.0a1
2019.1.9f1
2019.2.0a1
2019.3.0a1
Issue ID
1168207
Regression
Yes
Texture2D has distorted colors when JPG files are attached to Texture2D via script
Steps to reproduce:
1. Open users attached project "Test.zip"
2. Open "Main.scene"
3. Enter Play Mode
4. Use "Scale" of the Game View to zoom in to see more clearly the black & white rectangles
5. Note that the black is perfectly black
6. Select "Main Camera" and under "C main" component change Texture source to PatternJpg from Project -> Assets-> Textures
7. Note that some grey/white pixels appeared in Black coloured areas
Expected results: JPG images show the same colour as they were created
Actual results: JPG images show colour distortion when imported in Unity
Reproducible with: 2018.3.0a1, 2018.4.3f1, 2019.1.9f1, 2019.2.0b7, 2019.3.0a8
Not Reproducible with: 2017.4.29f1
Note: It appears that this issue reproduces only when attaching the jpg file to a Texture2D via script
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
- Shader Graph Node information is briefly displayed in Graph Inspector when clicking on Category in the Blackboard
- Module installation fails with "Download failed: Validation Failed" errors when using beta.2 Hub version
- JsonConvert conversion fails trying to call GetCallbackMethodsForType when [OnDeserialized] is used in a class
- Shader Graph Category dropdown cannot be expanded/collapsed when clicking on the text
- Different text alignment in the column header in Entities "System" window
Resolution Note:
By design as the JPEG coding artifacts getting amplified by texture magnification and rendering. The user should definitely not use JPEG source files for these type of textures. Freeimage seems to be decoding this JPEG with more artifacts than some other decoders, probably caused by FreeImage preferring faster processing over quality. So a user inspecting the original JPEG could see fewer artifacts than what he gets after Unity loads it through FreeImage.