3

The person who asked the question at the link below way back in 2011 said, "I understand that it is possible to incorporate Google StreetView into non-Google apps".

Can anyone tell me how this is possible? I'd like to add street view functionality to my leaflet map.

Open source alternatives to Google's StreetView engine?

1

To solve the issue of STREETVIEW I use leaflet library https://gist.github.com/crofty/2197042 google-Leaflet and also build upon the previous review and I could also accomplish this. I hope they serve.

http://jsfiddle.net/ALL4k/

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

1

According to https://cloud.google.com/maps-platform/terms/ this is against the terms of service.

If you don't mind incurring the wrath of Google, take a look at the StreetView API:

Street View Locations and Point-of-View (POV)

The StreetViewPanorama constructor also allows you to set the Street View location and point of view using the StreetViewOptions parameter. You may call setPosition() and setPov() on the object after construction to change its location and POV.

You could use your Leaflet map to set the location for the panorama, perhaps by modifying the example here (which uses Google Maps to set the location).

  • As always, you should check the license to verify that you're allowed to show a streetview image on a non-Google map. I've seen this done on Esri maps, but that doesn't mean it's legal – Stephen Lead Sep 7 '13 at 22:19
  • according to a comment in this answer, it is against the terms. Terms: cloud.google.com/maps-platform/terms (d) No Use With Non-Google Maps. Customer will not use the Google Maps Core Services in a Customer Application that contains a non-Google map. For example, Customer will not (i) display Places listings on a non-Google map, or (ii) display Street View imagery and non-Google maps in the same Customer Application. – Jeff Xiao Mar 14 at 13:40
  • @JeffXiao thanks, I updated the answer to mention this explicitly – Stephen Lead Mar 14 at 23:23
0

Better use this plugin:

https://github.com/Zverik/leaflet-streetview

Instant Street view in the leaflet location given

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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