Answer the question
In order to leave comments, you need to log in
How to calculate panorama view direction?
There is a marker on the map, according to some event, the panorama closest to it is searched. Let's say the panorama was found and opened. But there is no guarantee that the user will see the house that matches the marker. Most likely, for this he will have to independently rotate the panorama.
The documentation has an example of setting the panorama view direction. But it's not clear to me what mathematical formula can be used to calculate the direction I need (so that the panorama looks in the direction of the marker for which it was searched).
Please teach me how to do it. Or at least give links to similar examples.
pS:
As far as I understand, it is not enough to substitute the value of the marker coordinates in the direction. You need to calculate the rotation in azimuth.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question