Arcrotate camera on mobile

Noticed, the arc rotate camera on mobile is not as sharp as it should be or precise. Either it accelerates too fast when panning or pans slow. The pinch to zoom also pans the camera. and also can’t really focus on an object.

here are the settings i’m using:

    camera.pinchDeltaPercentage = 0.01;
    camera.wheelDeltaPercentage = 0.01;
    camera.useNaturalPinchZoom = true;
    camera.pinchPrecision = 10000;
    camera.minZ = 0.1;

maybe i’m missing something. I hate to compare but i will love something close to this orbitControl used by three.js JSFiddle

1 Like

Hi there

Here are my settings I used that I found were good for mobile , i see you set three variables I did not , "pinchDeltaPercentage " , "wheelDeltaPercentage " and "useNaturalPinchZoom " What did they do for you? I didnt have issues with my scene on mobile but also i cant say ive tested every kind of device either so if you have info about why you set these and it is indeed helpful then I would like to add it to my project as well. anyway here is what I have :

this.camera.wheelPrecision = 50;
this.camera.pinchPrecision = 700;
this.camera.panningSensibility = 1000;
this.camera.allowUpsideDown = false;
this.camera.lowerRadiusLimit = 0.01;
this.camera.minZ = 0.030;

1 Like

@shaderbytes

this is much better, Thanks! i added useNaturalPinchZoom to make the zoom more natural and reduced panningInteria because the camera was accelerating really fast when panning. here’s what i use now in case anyone else finds this post

    camera.wheelPrecision = 50;
    camera.pinchPrecision = 700;
    camera.panningSensibility = 1000;
    camera.allowUpsideDown = false;
    camera.lowerRadiusLimit = 0.01;
    camera.minZ = 0.030;
    camera.useNaturalPinchZoom = true;
    camera.panningInertia = 0.5
    camera.setTarget(rootmesh.position)
3 Likes