mrdoob/three.js — Issue #872: makeInvert removal
Author: inear
Created: 2011-12-08 07:38:21+00:00
State: open

Hi!

Is there a reason for the removal of the method makeInvert in Matrix4? I have previously used that to calculate position from local space to a parents space, like this:

var childWorldMatrix = childMesh.matrixWorld;
var tempParentMatrix = new THREE.Matrix4();
var inverse = new THREE.Matrix4();
THREE.Matrix4.makeInvert(scene.matrixWorld,inverse);
tempParentMatrix.multiply(inverse,childWorldMatrix );
spotLight.position = tempParentMatrix.getPosition();

Is there perhaps a smarter way of doing this? Some build-in function?

/Einar