August 2018
Intermediate to advanced
528 pages
10h 58m
English
The OrbitControl control is a great way to rotate and pan around an object in the center of the scene. With 08-controls-orbit.html, we've included an example that shows how this control works. The following screenshot shows a still image of this example:

Using OrbitControl is just as simple as using the other controls. Include the correct JavaScript file, set up the control with the camera, and use THREE.Clock again to update the control:
<script type="text/javascript" src="../libs/OrbitControls.js"></script> ... var orbitControls = new THREE.OrbitControls(camera); orbitControls.autoRotate = true; var clock = new ...
Read now
Unlock full access