Sie sind nicht angemeldet.

1

Dienstag, 23. November 2021, 00:25

A navigator like 3D Vista : load pano by arrows

Hello,

I've a question since few time ago..
How make a navigator with arrow keys ?
in details :

  • up : ahead next pano
  • down : behind pano
  • left and right : normal use

I know the nadir and zenith are not really use but i've more and more people wants this navigation. A matterport effect i presume.
I think its a good things to have the choice for navigate, classic and this one, with ou without depthmap.
Where can we start ? the keycode ?
A solution already exists and I haven't seen it ?
Thanks for you help

Damien
...sorry for my english :)

Scott Witte

Fortgeschrittener

Beiträge: 382

Wohnort: Milwaukee, WI USA

Beruf: Professional Photographer

  • Nachricht senden

2

Montag, 29. November 2021, 01:34

I suspect Google Street View is a bigger influence here than Matterport, not that it matters. Interesting idea, though.

If all you want is for the up and down keys to load the next and previous pano, you can edit the skin_keydown_event section in vtourskin.xml adding:

Quellcode

1
if(keycode == 38, skin_nextscene_loop(+1) );

But that won't give you the same behavior as Matterport or Street View where the up arrow takes you to the scene who's navigation arrow is closest to your center of view. That is especially obvious when you have three or more navigation hotspots in a scene.

To accomplish Street View navigation the up arrow would need to call an action that finds the navigation hotspot with an ath that most closely matches your current view hlookat. I would then call the click event for that hotspot.

Some caveats: You want to programmatically exclude any hotspots that aren't for navigation in the comparison. You also need to do some math to account for the 360 fov. For instance, if your current hlookat is 179 and there is a navigation hotspot with an ath of -179, those are are only 2 degrees apart, not 358. I believe you use the mod math function to make an accurate comparison.

It would be the opposite with the down arrow where you want the navigation hotspot farthest away from you current hlookat.

Hope that helps.

Scott

3

Dienstag, 21. Dezember 2021, 23:33

Hi,


So sorry for the delay.

Thanks ! yes i think is the good way too.

i've bought Everpano, i will see if the navigator plugin made i want.
long time subject but i always think is a good idea.
Damien