This one seems a little tricky.
When I export a GLB file from 3DS Max, enable vertex colors on my materials in three.js and display it, meshes with no colors ever having been set display black. Meshes I do explicitely set colors for display those custom set colors. Before I blame it on the BabylonJS exporters, I throw it into donmccurdy’s gltf viewer and alas, all colors come out as expected - custom colors are displayed, and meshes with no colors set previously are not affected by the mul because they default to white.
I am using a mesh.traverse() after GLTFLoader:
mesh.traverse(node => {
if (node instanceof THREE.Mesh) {
let material = node.material;
node.castShadow = true;
node.receiveShadow = true;
material.vertexColors = true;
...
node.material = material;
}
results in:
Using donmccurdy’s viewer:
So it must be something else, seeing as his app seems to be interpreting the same GLB file fine?
The materials in-scene are a mix of MeshStandardMaterial and (unlit) MeshLambertMaterial, but that doesn’t make a difference. Any pointers maybe? We are on r117.