-
-
Notifications
You must be signed in to change notification settings - Fork 41
Description
Description
I've been working on #16 and run into an issue where vertex colors don't load either for meshes or point clouds.
The vertex attribute descriptors appear correct:
VertexAttribute=Color, VertexAttributeFormat=UInt8, numComponents=4, elementSize=4
Attempting to access unityMesh.colors results in:
Unsupported conversion of vertex data (format 6 to 0, dimensions 4 to 4)
UnityEngine.Mesh:get_colors ()
If the resulting array (from unityMesh.colors) is read the results are all rgba(0,0,0,0), hence the black.
This applies to both point clouds (in my WIP implementation) and meshes (in main)
There's minimal discussion of MeshData online, but I did see this which suggests it could be a Unity issue.
Colors do load correctly in GLTFast when models are not draco compressed.
Environment
Unity 2020.3.15f2
DracoUnity main 9f5161b
Expected Behaviour
In three.js:

Point Cloud (vertex colors) on left, Mesh (vertex colors) in center, Mesh (no colors) on right.
