You are not logged in.

1

Monday, February 4th 2019, 6:40pm

Starting angle of a tour

Hi, maybe is a little stupid question, but how to set a panorama to start with drop-down effect: from up to horizontal when play.
https://www.virtualtur.md/public/social/…2018/index.html
thanks!

2

Friday, March 1st 2019, 5:12pm

I would do in two steps:
-First you should set your initial viewing angle in the "view" tag defining the hlookat vlookat and fov paramaters.
-The change of angle should be called in the scene "onstart", either directly inside it, or by defining an action.
-On the sample link you provided, autorotate gets activated after reaching the target angle. You can set this at the end of the last tween.

Here's a sample code that starts a scene looking up (vlookat=-50), and after it starts, it turns the vewing direction 45 degrees and levels it (vlookat = 0) using the default tween type, during a period of 1 second. After leveling the view, autorotate gets started.

Hope it helps.

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
	<scene name="scene01" title="Sample Scene" onstart="changeAngle();" ...>

		<view hlookat="0 vlookat="-50" fovtype="MFOV" fov="120.000" ... />

		<image>
		...
		</image>

		<hotspot name="spot1" .... />
		...
		</hotspot> 
	</scene>


	<action name="changeAngle">
		tween(view.hlookat, 45, 1);
		tween(view.vlookat, 0, 1, default, set(autorotate.enabled, true));
	</action>