How to embed photosphere without using Google Maps?

173 views Asked by At

I'm trying to embed a photosphere onto my website. The usual solution is to contribute the photosphere to Google Maps and then use their embed facility. Unfortunately, I can't do that with this particular photosphere because it isn't of a fixed location - it is inside a cruise ship. I'm reluctant to contribute it to a "random" location on Earth as it might result in Google removing it.

I found https://thenextweb.com/news/google-launches-photo-sphere-viewing-widget-for-embedding-images-in-any-website-not-just-google-and-maps and although http://apis.google.com/js/plusone.js still works, I cannot figure out what URL I should provide for the image. I've tried a share link from Google Photos and I've tried a URL from within my website. Neither works.

I've also found https://github.com/kennydude/photosphere but that doesn't seem to work, giving the error "THREE.CanvasRenderer is not a constructor" and the repository clearly states "THIS IS VERY OLD AND YOU SHOULD NOT USE THIS."

Any suggestions, please? Is there any code or method I can use to display/render a non-Google-hosted photosphere?

Thanks.

1

There are 1 answers

0
Philip Colmer On

Since posting this question, I've found a nice open source library that handles this need precisely: https://photo-sphere-viewer.js.org/