ArcRotateCamera SetPosition and SetTarget question

I’m trying to when click one button, the camera position and alpha, beta, radius, should match what I set, but when I click, the behavior is not expected,

Camera movement | Babylon.js Playground (

What the camera angel expected

Hey there, you can’t pass alpha beta, and radius to setPosition but you can set those properties on the camera like below and I think get what you’re after. :slight_smile:

Thank you @Blake, that’s what I need, but I just see the definition for setPosition mentioned alpha, beta, radius, so I thought that’s the way to set it

setPositionSearch playground for setPosition

  • setPosition(position: Vector3): void

  • Use a position to define the current camera related information like alpha, beta and radius

For example if you log camera.position then you could pass that value to camera.setPosition and it will automatically set the corresponding alpha, beta, and radius for you.

Or you can set the alpha, beta, and radius properties and let the camera set the corresponding position for you instead of setting it directly.