|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
<hotspot name="spot1" style="hotspotstyle" ath="0" atv="0" linkedscene="pano1" />
<hotspot name="spot2" style="hotspotstyle" ath="30" atv="0" linkedscene="pano2" />
<hotspot name="spot3" style="hotspotstyle" ath="60" atv="0" linkedscene="pano3" />
<hotspot name="spot4" style="hotspotstyle" ath="10" atv="20" linkedscene="pano4" />
<hotspot name="spot5" style="hotspotstyle" ath="-10" atv="35" linkedscene="pano5" />
<hotspot name="spot6" style="hotspotstyle" ath="0" atv="60" linkedscene="pano6" />
<hotspot name="spot7" style="hotspotstyle" ath="170" atv="30" linkedscene="pano7" />
<events name="testshotspots" keep="true" onviewchanged="testhotspots();" />
<action name="testhotspots">
for(set(i,0), i LT hotspot.count, inc(i),
getlooktodistance(d, hotspot[get(i)].ath, hotspot[get(i)].atv);
if(d LT 10,
highlight_hotspot(get(i), get(hotspot[get(i)].linkedscene));
,
background_hotspot(get(i), 0.5, 0.5);
);
);
</action>
<action name="highlight_hotspot">
if(hotspot[%1].ishighlighted != true,
set(hotspot[%1].ishighlighted, true);
tween(hotspot[%1].scale, 2.0, 2.0, default, loadscene(%2,null,MERGE,BLEND(1)) );
);
</action>
<action name="background_hotspot">
set(hotspot[%1].ishighlighted, false);
tween(hotspot[%1].scale, 0.5, 0.5);
</action>
|
Location: Netherlands
Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

: https://pame.virtualtuur.comThis post has been edited 2 times, last edit by "Tuur" (Oct 14th 2014, 2:16pm)