Sie sind nicht angemeldet.

1

Freitag, 31. August 2012, 14:29

Onclick on hotspot ineffective - help

Hi,

I'm getting nuts with this ...

I've got a virtual tour with hotspots (sounds very normal ;-)). Hotspots are
working - no problem.

It is this one:

http://www.360-grad-panoramafotografie-h…_meinl/tour.php

When clicking one of the hotspots there is a zoom in to the hotspot position
an to a fov of ???
Then it is blended to the next panorama (to the view that's set up in the
<view> tag - hlookat, vlookat, fov).

What I want is:

- click on a hotspot
- zoom in to the hotspot
- blend to the next panorama (start view from that next panorama should
be the same as the last view when it is zoomed in to the hotspot)
- zoom out to a specified hlookat, vlookat and fov

My hotspots look like this, when created with the tour editor:

Quellcode

1
<hotspot name="spot1" style="skin_hotspotstyle" ath="-55.661" atv="19.325" linkedscene="scene_panorama_2" />


After looking at several virtual tuors, that were created with krpano I tried
it with something like this in the <hotspot> tag (this is a hotspot snippet from
the krpano viewer example folder "examples - virtual-tours - demotour-wein-
gut - tour.xml with my hotspot parameters):

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
		<hotspot name="spot1"
		     	style="skin_hotspotstyle"
			 	ath="92.733" 
			 	atv="9.362"
			 	linkedscene="scene_Panorama_2"
		     	onclick="set(enabled,false);
			          	set(view.maxpixelzoom,null);
			          	set(view.fovmin,28);
			          	lookto(10.7, 3.5, 42);
			          	loadscene(scene_Panorama_2, null, MERGE, BLEND(2));
			          	lookat(-94, 19, 97);
			          	wait(LOAD);
			          	oninterrupt(break);
			          	wait(BLEND);
			          	lookto(-352.7, -1.6, 108, smooth(45,45,60), false);"
			/>


but that changes nothing. Weird :-/ You can check it out in my tour -
the hotspot "Zum Gastraum" in pano 1 has these settings, the hotspot
"Zum Eingang" in the second panorama has the settings from the first
code example. There is absolutely no difference in the behaviour of
the hotspots. I really can't unterstand that.

Where is my mistake here? Any help appreciated :-)

Thanks in advance and regards,

Josch

2

Samstag, 1. September 2012, 12:24

Hi,

the 'onclick' event was already defined the 'skin_hotspotstyle' style - and the settings from the <style> will overwrite the settings from the element itself at start.

Best regards,
Klaus

3

Dienstag, 4. September 2012, 13:30

Hi Klaus,

thanks a lot for your support :-)

I haven't reckoned with this double onclick action so I searched everywhere for the error but not THERE :-)

Now it works as expected and I unterstand krpano better and better.

Regards,

Josch