3

I have some polygon data in .shp format to show in Google Maps Satellite view. I can show them well until certain zoom level.

enter image description here

But after certain level (zoom level 17 or 18), OpenLayers layer and Google Maps Satellite layer displace each other like this.

enter image description here

We know Google Maps Satellite View changes it camera angle after certain zoom level and put it to 45 degrees. How can i resolve this with OpenLayers.

1 Answer 1

4

This was recently fixed. If you are not able to use the latest version, you can do the following after adding your Google layer to the map (here: myGoogleLayer):

myGoogleLayer.mapObject.setTilt(0);
2
  • When I add this line googleSatellite.mapObject.setTilt(0), browser shows me this Uncaught TypeError: Cannot call method 'setTilt' of null. Then I add tilt: (this.useTiltImages ? 45 : 0) to map options and nothing changes.
    – Moshii
    Commented Mar 9, 2014 at 6:41
  • You have to add the layer to the map before calling setTilt() on the mapObject. The second attempt you describe does not make sense at all.
    – ahocevar
    Commented Mar 10, 2014 at 7:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.