You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Thursday, June 26th 2014, 3:04pm

Plugin for visual navigation and pano orientation

Hi, there is a plugin for to navigate my tour and mantain the orientation of it?

For example: if i click to my hotspot to enter in one room, when i enter in it, the default angle of orientation is always the same and if i return to the main room too.
I need a solution for to mantain the orientation, from one room to other (like google street view).

I have find a solution with some line of code, but i have to set manually the angle for every pano in my xlm hotspot.
that i'm finding is a automatic solution to keep the orintation from current scene and apply it to the next scene.

Any idea?
Thanks.

jordi

Intermediate

Posts: 465

Location: Barcelona

Occupation: creating ideas & coding them

  • Send private message

2

Thursday, June 26th 2014, 4:18pm

For doing that in an automatic way, first you should have every pano with an orientation value set in the scene or in any other array, also you could have them previously oriented in the same direction (in photoshop ) so that value could be 0 all the time, and so you don't even have to set up this.

Then of course you will need some code that proces that values.
Basically you need to compare the view.hlookat from current pano and the values of orientation of both panos. And then you can get the view.hlookat of next pano.

If you have them oriented previously, then just make a keepview flag for the loadpano.

Hope it helps
everpano.com step beyond 360

3

Thursday, June 26th 2014, 4:28pm

i think there will be 2 ways!

1 you can use PTgui set the center of pano to same orientation (change X),for example ,to east,that all your pano hlookat="0" means to the east direction,and you can just use KEEPVIEW http://www.krpano.com/docu/actions/#loadscene



2

Source code

1
2
add(a,view.hlookat,layer[radar].heading);
   mod(b,a,360);


before enter a new scene,get b,
then in the new scene sub(view.hlookat,b,layer[radar].heading); and you get view.hlookat

maybe you can use push/pop

jordi

Intermediate

Posts: 465

Location: Barcelona

Occupation: creating ideas & coding them

  • Send private message

4

Thursday, June 26th 2014, 5:31pm

Quoted

before enter a new scene,get b,then in the new scene sub(view.hlookat,b,layer[radar].heading); and you get view.hlookat



I think that with this method, pano would be loaded in the default point of view and then just jump to the correct one. So every calculation should be done before loading pano
everpano.com step beyond 360

5

Friday, June 27th 2014, 2:20am

my poor english,yes,that is what i mean

6

Saturday, June 28th 2014, 2:46am

I found sth useful for your need
http://www.krpano.com/docu/actions/#loadpano
vars* can send sth to new pano but before starting the pano viewing.