I am using raycaster to define the face of a cube and then paint the face like this
const colorAttribute = intersected.object.geometry.getAttribute('color');
colorAttribute.setXYZ(face.a, color.r, color.g, color.b);
colorAttribute.setXYZ(face.b, color.r, color.g, color.b);
colorAttribute.setXYZ(face.c, color.r, color.g, color.b);
colorAttribute.needsUpdate = true;
But as you can see, the face is not completely painted over. Can someone help? https://jsfiddle.net/kirill321592/fjdxpos1/43/