I have a ThreeJS scene that uses OrbitControls.js to move and zoom a PerspectiveCamera around a target.
I would like to save the camera zoom (or/and fov) values of my application to a local file to be loaded later, but it seems that OrbitControls.js zoom method is based on changing the camera position instead of using camera.zoom or camera.fov properties (these remain unchanged).
My questions are:
- Is there any advantage in changing the camera position vs zoom or fov?
- Should I use a different camera controller instead? If so, is there an alternative to OrbitControls.js that uses zoom/fov values?
- I want my saved value to be as ‘standard’ as possible. Should I convert (somehow) the camera position to corresponding zoom/fov values or just store the x,y,z position, or all of them?