# How to make camera rotate around the object?

**URL:** <https://discourse.threejs.org/t/how-to-make-camera-rotate-around-the-object/34734>\
**Category:** Questions\
**Created:** [February 10, 2022, 6:19pm UTC](https://discourse.threejs.org/t/how-to-make-camera-rotate-around-the-object/34734 "2022-02-10T18:19:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Archoni](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/archoni/32/24082_2.png) [@Archoni](https://discourse.threejs.org/u/Archoni)\
**Post date:** [February 10, 2022, 6:19pm UTC](https://discourse.threejs.org/t/how-to-make-camera-rotate-around-the-object/34734/1 "2022-02-10T18:19:12Z")

</div>

I had to create an interior camera of my object and for that to work I had to offset my object from the center. Now the problem is that I want the camera to rotate from the center of the object and not around the center of my scene. Here are some images [one](https://ibb.co/CwV0GqV) [two](https://ibb.co/GtxYG75) [three](https://ibb.co/SctsL7F) that will explain the problem. As you can see, looking at the car from the back it appears closer than looking from the front.

```javascript
    const fov = 75;
    const near = 0.1;
    const far = 1000;
    const camera = new THREE.PerspectiveCamera(fov, window.innerWidth / window.innerHeight, near, far);
    camera.position.set(0, 1, 4);

```

```javascript
    const controls = new THREE.OrbitControls(camera, renderer.domElement);
    controls.maxPolarAngle = Math.PI / 2;
    controls.minPolarAngle = Math.PI / 3;
    controls.maxDistance = 5;
    controls.minDistance = 3;
    controls.autoRotate = true;
    controls.autoRotateSpeed = 0.2;
    controls.enableDamping = true;
    controls.enablePan = false;
    controls.addEventListener( "change", event => {
    console.log( controls.object.position );
    });
    controls.update()

```

---

<div class="post-metadata">

**Author:** ![prisoner849](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/prisoner849/32/535_2.png) [@prisoner849](https://discourse.threejs.org/u/prisoner849)\
**Post date:** [February 10, 2022, 7:41pm UTC](https://discourse.threejs.org/t/how-to-make-camera-rotate-around-the-object/34734/2 "2022-02-10T19:41:41Z")

</div>

/cc

> <https://stackoverflow.com/questions/71071175/three-js-how-to-make-the-camera-rotate-around-the-center-of-an-object>
