UNPKG

@woosh/meep-engine

Version:

Pure JavaScript game engine. Fully featured and production ready.

15 lines (13 loc) 414 B
// /** * * @param {Vector3} result * @param {Vector3} input * @param {number[]} projection_matrix_inverse inverse of projection matrix * @param {number[]} world_matrix world transform */ export function unprojectPoint(result, input, projection_matrix_inverse, world_matrix) { result.copy(input); result.applyMatrix4(projection_matrix_inverse); result.applyMatrix4(world_matrix); }