Code is a little modified version of webgl interactive draggable cubes
5 meshes is created with new THREE.Mesh
(red) and 5 with new THREE.SceneUtils.createMultiMaterialObject
(blue)
[sorry, example deleted]
Please try to drag them, red and blue cubes moves differently.
Red cube moving is related to the mouse (screen) if I drag one cube to the left, cube moves to the left. Blue cube moving is related to the ??rotated coordinate system (or camera rotation)?? , if i drag one cube to the left, cube can move up or down and faster than mouse.
I assume it is because createMultiMaterialObject
is a group of THREE.Mesh with the same geometry and different materials. Anyway I can't see a reason. Why they move differently?
How to make red and blue cubes behave equally onDocumentMouseMove
?