center是Yuka JavaScript库中BoundingSphere的属性,表示包围球的中心位置。
包围球是一种可以完全包含给定物体(例如模型或点云)的球形几何体,常用于碰撞检测、可视化、遮挡检测等场景。
sphere.center
Vector3
(0, 0, 0)
const sphere = new YUKA.BoundingSphere();
console.log(sphere.center); // 输出: { x: 0, y: 0, z: 0 }
(0, 0, 0),表示世界坐标系原点。sphere.center.set(1, 2, 3)。