0
votes

I wrote some PHP script, to get static image from Street View Static image API after giving the script usual Google Maps URL.

But, then I set position of Street view to the ground, and run my script, I get the image of sky, and vice-verse.

Here is an example.

Usual Google Maps url: https://maps.google.com/?ll=54.899267,23.884749&spn=0.022086,0.062485&t=m&z=15&layer=c&cbll=54.898264,23.885077&panoid=eu75VjoUqNejdSOUJEoCdA&cbp=12,17.61,,0,36.53 <- pitch = 36.53 )

And here is static image from API: http://maps.googleapis.com/maps/api/streetview?size=640x400&location=54.898264,23.885077&heading=17.61&pitch=36.53&fov=70&sensor=false As you can see, pitch is same size, but picture shows the sky.

If you invert pitch (-36.53), then everything is ok.(I can't show i, because of reputation, no more than 2 links).

Is this a some bug or what? I don't find any information about this thing.

1

1 Answers

1
votes

It really appears that the values are inverted, but there is no bug.

The parameters for Google-Maps AFAIK are not official documented, so the mistake here is that you rely on these parameters.

But the parameters for the Street View Image API are documented:
* pitch (default is 0) specifies the up or down angle of the camera relative to the Street View vehicle. This is often, but not always, flat horizontal. Positive values angle the camera up (with 90 degrees indicating straight up); negative values angle the camera down (with -90 indicating straight down).*