【发布时间】:2022-01-19 17:29:34
【问题描述】:
我可以使用带有OrbitControls 的鼠标将相机从默认位置[0,0,0] 平移到[100,100,0]。但是仍然无法通过代码进行平移。
<Canvas
camera={{
position: [0, 0, 100],
up: [0, 0, 1],
}}
>
<OrbitControls />
<ambientLight />
<FakeSphere position={[0, 0, 0]} color="red" />
<FakeSphere position={[100, 100, 0]} color="blue" />
</Canvas>
请有什么想法。
【问题讨论】:
标签: three.js react-three-fiber react-three-drei