Search Issue Tracker
Fixed in 2021.1.X
Fixed in 2018.4.X, 2019.4.X, 2020.1.X, 2020.2.X
Votes
14
Found in
2017.4.0f1
2018.2.14f1
2018.3.0a1
2019.1.0a1
2019.2.0a1
Issue ID
1120359
Regression
No
[WebGL] Normal Maps produce wrong lighting on WebGL build when appropriate Unity shader is put into Always Included Shaders list
How to reproduce:
1. Create a new project and import the attached package "case_1120359-NormalsWebGL_package"
2. Add "mobile/Bumped Diffuse" shader to Project Settings -> Graphics -> Always Included Shaders list
3. Build project with scene "TargetDeffered" for WebGL target with default settings
4. Run the built project and observe output in the browser
Expected result: normal map on spinning plane works correctly (normal mapped features appear lit from the right)
Actual result: normal map behaves incorrectly (produces wrong surface lighting)
Reproducible with: 2017.4.19f1, 2018.3.3f1, 2019.1.0b1, 2019.2.0a3
Note: the user reports that this issue is also present when using the "Standard", "Standard (Specular Setup)", but not when using LWRP. The user has some more details in his forum thread: https://forum.unity.com/threads/normal-map-not-working-when-adding-standard-in-always-included-shaders.595639/
-
firala
Sep 01, 2020 10:50
Same issue here in 2019.3.6f1 when using Addressables.
-
flipddr
Jul 29, 2020 20:40
Spent a couple days trying to fix it. I'm using the Universal RP, and changing the material shader to URP/Baked Lit instead of URP/Lit did it for me. Hope this helps someone.
-
OneManArmy3D
Jan 06, 2020 14:24
Yes, normalmaps are broken when loading maps in WebGL using addressables. In editor and standalone everything is fine.
Here in video you can see result without/with normalmaps.
https://www.youtube.com/watch?v=DFoloU8LUXA -
Twyker_gp
Sep 11, 2019 09:56
Can confirm that this also happens with asset bundles that were built with the addressable asset system.
-
TheZkip
Mar 05, 2019 16:32
Potentially related to asset bundles as well:
https://forum.unity.com/threads/normal-map-not-working-when-adding-standard-in-always-included-shaders.595639/#post-4284316
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
- SpeedTree does not move when using WindZone
- "Undeclared identifier 'LinearToSRGB'" error is thrown when creating a color variable with HDR color mode and assigning a Custom Render Texture target in Shader Graph
- Input System package is missing when creating a new HDRP project
- Inconsistent behaviour when interacting with different dropdown types with pointer events on parent Visual Element
- Hidden GameObjects won't re-enable when they have call "DontDestroyOnLoad" function
Resolution Note (fix version 2019.4):
Fixed in: 2019.4.14f1