math - Convert three.js scene rotation to polar coordinates? -


given three.js scene, how 1 calculate theta , phi polar coordinates x, y , z position , rotation property values of three.perspectivecamera?

you need take x, y, , z coordinates , plug them following equations:

enter image description here

enter image description here

enter image description here

source: https://en.wikipedia.org/wiki/spherical_coordinate_system