Search Issue Tracker
By Design
Votes
0
Found in [Package]
4.0.4
Issue ID
1143495
Regression
No
ProBuilder Mesh loses vertex color information when doing unrelated operations
How to reproduce:
1. Open the attached project in the OC.
2. Select "Cube" in the Hierarchy
3. Move it with a Transform tool.
4. Press CRTL+Z to Undo the position
Expected result: Mesh keeps vertices colors
Actual result: Mesh loses vertices colors
Reproducible with - 2018.3.13f1, 2019.1.0f1, 2019.2.0a11
Could not test with - 2017.4 (too many errors)
Package versions tested: 3.0.0 - 4.0.4
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
- The UI is not visible when resizing out of focus built Player window with Application.runInBackground set to false
- [Linux] "Error while reading movie" errors are thrown when opening templates
- Standalone profiler process is hidden in macOS dock
- Shader warnings are being thrown after building Mixed Reality Template
- Error is thrown when entering play mode with build profiles docked and standalone profiler open
Resolution Note:
The vertex painting tool in the project is applying color values directly to the MeshFilter's shared mesh. ProBuilder by design overwrites the values on that mesh, meaning any modifications made to the mesh will be lost. See the Scripting API Overview for more information on why https://docs.unity3d.com/Packages/com.unity.probuilder@4.0/manual/api.html.
To apply vertex colors on a ProBuilder created mesh, you should set the `colors` property on the `ProBuilderMesh` component. See https://docs.unity3d.com/Packages/com.unity.probuilder@4.0/api/UnityEngine.ProBuilder.ProBuilderMesh.html#UnityEngine_ProBuilder_ProBuilderMesh_colors