Title describes the issue - full instances will only use the source mesh’s alpha.
Demo
Relevant state info
// mesh1 is a full instance, mesh2 is a thin instance
{
"mesh1.isVerticesDataPresent(BABYLON.VertexBuffer.ColorInstanceKind)": false,
"mesh1.hasInstances": true,
"mesh1.hasThinInstances": false,
"mesh2.isVerticesDataPresent(BABYLON.VertexBuffer.ColorInstanceKind)": true,
"mesh2.hasInstances": false,
"mesh2.hasThinInstances": true
}
Relevant locations in the codebase
Based on the state above, INSTANCESCOLOR
will not be defined for full instances:
Resulting in the following line not being compiled into the shader: