mpetroff / pannellum

Pannellum is a lightweight, free, and open source panorama viewer for the web.
https://pannellum.org/
MIT License
4.3k stars 729 forks source link

How to Load Google Pano Images? #492

Closed pegues closed 7 years ago

pegues commented 7 years ago

How to load google's pano images? I've tried the equirectangular and multires types, and the result comes out horribly. Can someone please share an example configuration for loading google panos that have a folder structure such as: pano/__WNYkII_ZVn1HebX4Y7XA/0/0 with images 0.jpg, 1.jpg, 2.jpg, and 3.jpg ? I'd greatly appreciate it. An example of the panos is attached:

__WNYkII_ZVn1HebX4Y7XA.zip

I've tried the following setups, but with very little success. And using cubeMap, I get an error every time that says: "The file http://localhost:3210/undefined could not be accessed."

The access error is not displayed for the same path used for the equirectangular and multires types.

My setup is below: ` pannellum.viewer(

'panoviewer', {
'autoLoad'      : true,
'compass'       : true,
'northOffset'   : 247.5,
'type'          : 'equirectangular',
'panorama'      : '/aoi/panos/__WNYkII_ZVn1HebX4Y7XA/3/1/0.jpg'
/*
'type':'multires',
'multiRes': {
    'basePath': '/aoi/panos/__WNYkII_ZVn1HebX4Y7XA',
    //'path': '/%l/%y/%x',
    'path': '/%l/%x/%y',
    'extension': 'jpg',
    'tileResolution': 512,
    'maxLevel': 6,
    'cubeResolution': 8432
}
*/

/*
'type': 'cubemap',
'cubeMap': [
    '/aoi/panos/__WNYkII_ZVn1HebX4Y7XA/0/0/0.jpg'
]
*/
}

);

mpetroff commented 7 years ago

Google's horrible, tiled equirectangular format isn't supported. I'm also not going to condone your copyright infringement of Google's Street View images.