赞
踩
//首先要有raycaster控制器
mouse.x = (e.clientX / width) * 2 - 1;
mouse.y = -(e.clientY / height) * 2 + 1;
let raycaster = new THREE.Raycaster();
raycaster.setFromCamera(mouse, camera);
let intersects = raycaster.intersectObjects(scene.children);
if(intersects.length > 0
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。