Basically I wanted to translate the position of the gizmo line along axis X. When setting the following configuration over the mesh, the translation does not work:
Original Gizmo mesh:
for (const key in gizmo.translate.children) {
const giz = gizmo.translate.children[key];
if (giz.name === "X") {
if (count === 0) {
console.log(giz);
giz.applyMatrix4(
new THREE.Matrix4().makeTranslation(
-0.5,
0,
0
)
);
giz.updateMatrix();
}
count++;
}
}
however, when applying the translation over the bufferGeometry, it works:
let count = 0;
for (const key in gizmo.translate.children) {
const giz = gizmo.translate.children[key];
if (giz.name === "X") {
//0 is the arrow body
if (count === 0) {
giz.geometry.applyMatrix4(
new THREE.Matrix4().makeTranslation(
-0.5,
0,
0
)
);
// giz.updateMatrix();
// giz.visible = false;
// giz.layers.disable(0);
}
count++;
}
}
Iām confused about this, can someone make some clarifications about this behavior?