# I'm Trying to use OrbitControls but i can't, Any help?

**URL:** <https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882>\
**Category:** Questions\
**Tags:** orbit-controls\
**Created:** [February 19, 2018, 11:27am UTC](https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882 "2018-02-19T11:27:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![AmjadKh94](https://avatars.discourse-cdn.com/v4/letter/a/c77e96/32.png) [@AmjadKh94](https://discourse.threejs.org/u/AmjadKh94)\
**Post date:** [February 19, 2018, 11:27am UTC](https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882/1 "2018-02-19T11:27:07Z")

</div>

HI, Im trying to use orbit controls but the scene is empty, how to deal with it?

```
activeCamera = new THREE.PerspectiveCamera(tempCameraJS.fov, tempCameraJS.aspect, tempCameraJS.near, tempCameraJS.far);
activeCamera .cameraTarget = tempCameraJS.cameraTarget.clone();
activeCamera .up = tempCameraJS.up.clone();
activeCamera .position = tempCameraJS.position.clone();
  
 activeCamera .aspect = 592 / 561; 
 activeCamera .updateProjectionMatrix();
 scene.ThreeSceneJSVar.add( activeCamera );
 controlsJS = new THREE.OrbitControls(activeCamera);
 controlsJS .noPan = true;
 controlsJS .noZoom = true; 
 controlsJS .autoRotate = true;
 controlsJS .autoRotateSpeed = 0.5;
```

---

<div class="post-metadata">

**Author:** ![Mugen87](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/mugen87/32/5645_2.png) [@Mugen87](https://discourse.threejs.org/u/Mugen87)\
**Post date:** [February 19, 2018, 2:41pm UTC](https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882/2 "2018-02-19T14:41:56Z")

</div>

You have to call `controls.update()` in your animation loop when `autoRotate` is set to `true`.

[https://jsfiddle.net/f2Lommf5/1421/](https://jsfiddle.net/f2Lommf5/1421/)

Besides, `noPan` and `noZoom` are deprecated. Use `enablePan` and `enableZoom` instead.

---

<div class="post-metadata">

**Author:** ![AmjadKh94](https://avatars.discourse-cdn.com/v4/letter/a/c77e96/32.png) [@AmjadKh94](https://discourse.threejs.org/u/AmjadKh94)\
**Post date:** [February 20, 2018, 7:44am UTC](https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882/3 "2018-02-20T07:44:33Z")

</div>

Still have the same problem,

> ```
> controlsJS= new THREE.OrbitControls(activeCameraJSVar);
> controlsJS.enablePan = false;
> controlsJS.enableZoom = true; 
> controlsJS.autoRotate = true;
> 
> ```

and in the animation :

> controlsJS.update();

First image is the log

 ![Capture](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/2X/c/ccfb8a64f7a328793ede2e1ef26599a1746e2521.PNG)

and this is the output screen… totally empty!

 ![Output%20screen](https://canada1.discourse-cdn.com/flex035/uploads/threejs/original/2X/9/903ce2a4549429c3e4c0dbfea6b02a32a95bb61c.PNG)

---

<div class="post-metadata">

**Author:** ![Mugen87](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/mugen87/32/5645_2.png) [@Mugen87](https://discourse.threejs.org/u/Mugen87)\
**Post date:** [February 20, 2018, 9:52am UTC](https://discourse.threejs.org/t/im-trying-to-use-orbitcontrols-but-i-cant-any-help/1882/4 "2018-02-20T09:52:42Z")

</div>

I can’t help you with the information you’ve provided so far. Try to create a [live example](https://jsfiddle.net/f2Lommf5/) with your current progress.
