I've got a marker on a map (v.3).
I then bring up the default panorama (.getStreetView()), using 
marker.getPosition() for panorama.setPosition().
 
I then have to manually rotate the street view to find my marker. This is 
the step I want to avoid.
But I can't seem to be able to calculate the heading value for setPov().
 
I've tried computeAngle() function from this 
example<http://gmaps-samples.googlecode.com/svn/trunk/streetview/angletowardsbuilding.html>,
 
but it doesn't seem to help, as in the example the coordinates of the 
panorama POV and the marker are indeed different, but in my case, they are 
"same," so the function always returns 0.
 
I'm putting quotes arond "same" because on the actual display they are not. 
A panorama POV is always in the middle of the road, whereas a marker, even 
created with the same LatLng, is always on the side of the road, against an 
actual building. So the marker is visible at certain heading, and not 
visible otherwise.
 
How can I calculate that heading?

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Reply via email to