Search Issue Tracker
By Design
Votes
0
Found in
5.3.1f1
Issue ID
757592
Regression
Yes
Combined static batched mesh changes UV coordinates when playing the scene
To reproduce the issue follow the steps:
1. Open StaticBatchingBug scene from attached project.
2. Notice how it looks in scene view.
3. Press "Play".
4. You will see texture shifts and uv is slightly different
Regression from 5.2
Reproduced in 5.3.1p1 (7d3d8e90548b), 5.3.1f1 (cc9cbbcc37b4)
Not reproducible in 5.2.2p3 (75b999ee8bfd), 5.1.2p2 (207c2b8718a4)
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
- Inconsistent ShaderGraph RGBA channels compared to the Inspector when "Alpha Is Transparency" is used
- Crash on "The GUID inside 'Assets/asset.png.meta' cannot be extracted by the YAML Parser." when opening the project
- Shadows disappear when looking at a certain angle in Scene view and using Cloud Shadows with Volumetric Clouds
- StackOverflowException freezes or silently crashes the Editor
- Microsoft Surface Device freezes when detaching and reattaching physical keyboard attachment to the device in Standalone Player for Windows
JakeTurner
Apr 26, 2016 05:28
Internally in the batching code Unity assumes UV2 will be used for lightmaps. Hence when batching the meshes in the test scene it is applying the lightmap scale & offset to the UV2 stream for those meshes which are included in the lighting mapping process. The fix for this use case is for the mesh with the custom UV2 stream and custom shaders to be disabled from the lightmapping generation process then its lightmap scale & offset will be 1,1,0,0 (identity) and texture will not shift when it is batched. Click the "Static" dropdown menu on the mesh to mark it is as static for all of areas except Lightmapping.