How to aviod camera movement on 3D objects?

Hi Friends!

how can we avoid camera movement on a 3D object within it´s scene?

I created my scene in react.js aka next.js, so I use react-three.fibre and react-three-drei. When I checked everything on my mobile phone I noticed that the camera is moving when I touch it with two gingers or when I make a right mouse click.

Thanks for help!

drei/camera-controls in react-three-fiber & yomotsu/camera-controls in vanilla three.js should help you with that :relieved:

You can pass a list of meshes to .colliderMeshes argument - that way camera will know to avoid these objects when moving around (example.)

I touch it with two gingers

damn, I want that kind of party