I am having problems regarding the switching of two viewpoints.
Whenever I move from viewpoint1 to viewpoint2 the rotation when I arrive at viewpoint2 seems off.
At first I wanted to switch viewpoints and this would involve setting the camera position. This doesn't seem possible so I had to wrap the camera with a container like so:
<a-entity><a-camera></a-camera></a-entity>
And then use .setAttribute('position', xyz); on the a-entity tag (I know the object3d approach is favorable, I still need to refactor this).
Now when I look from viewpoint1 to viewpoint2 (we call this movement deltaRotation) and switch viewpoints I change the rotation of the entity to my preferred point of view, lets say 0, 45, 0.
What I expect is that I end up at viewpoint2 with the camera looking at 0, 45, 0. The camera however seems to be looking at 0, 45, 0 + deltaRotation.
Is this the way I am supposed to be switching viewpoints? If so is this "tank" model way of working intended? Or should I take another approach.