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.
Location: Netherlands
Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer
![]() |
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 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 |
<krpano logkey="true" onstart="startup();map_vars();" > <include url="vtourskin.xml" /> <include url="actions_move_mobile.xml" /> <include url="map.xml" /> <include url="vars.xml" /> <include url="compass.xml" /> <action name="startup"> if(startscene === null, copy(startscene,scene[0].name)); loadscene(get(startscene), null, MERGE); </action> <scene name="scene_huis_1" title="1" onstart="setmapspots();" thumburl="panos/huis_1.tiles/thumb.jpg" heading="55"> <view hlookat="0" vlookat="0" fovtype="MFOV" fov="70" maxpixelzoom="2.0" fovmin="30" fovmax="120" limitview="auto" /> <include url="aircompass/aircompass.xml" /> <preview url="../../../vosbergen/mobile/panos/huis_1.tiles/preview.jpg" /> <image> <cube url="../../../vosbergen/mobile/panos/huis_1.tiles/pano_%s.jpg" /> <mobile> <cube url="../../../vosbergen/mobile/panos/huis_1.tiles/mobile_%s.jpg" /> </mobile> </image> <hotspot name="hs1" style="skin_hotspotstyle_black" ath="35.821" atv="6.382" linkedscene="scene_vos_2" /> </scene> <scene name="scene_vos_2" title="2" onstart="setmapspots();" thumburl="panos/vos_2.tiles/thumb.jpg" lat="" lng="" heading=""> <view hlookat="0" vlookat="0" fovtype="MFOV" fov="70" maxpixelzoom="2.0" fovmin="30" fovmax="120" limitview="auto" /> <include url="aircompass/aircompass.xml" /> <preview url="../../../vosbergen/mobile/panos/vos_2.tiles/preview.jpg" /> <image> <cube url="../../../vosbergen/mobile/panos/vos_2.tiles/pano_%s.jpg" /> <mobile> <cube url="../../../vosbergen/mobile/panos/vos_2.tiles/mobile_%s.jpg" /> </mobile> </image> <hotspot name="hs2" style="skin_hotspotstyle_black" ath="0.5567018186254984" atv="15.731434768064597" linkedscene="scene_huis_1" /> <hotspot name="hs2_2" style="skin_hotspotstyle_black" ath="180" atv="15.731434768064597" linkedscene="scene_vos_3" /> </scene> <scene name="scene_vos_3" title="3" onstart="setmapspots();" thumburl="panos/vos_3.tiles/thumb.jpg" lat="" lng="" heading=""> <view hlookat="0" vlookat="0" fovtype="MFOV" fov="70" maxpixelzoom="2.0" fovmin="30" fovmax="120" limitview="auto" /> <include url="aircompass/aircompass.xml" /> <preview url="../../../vosbergen/mobile/panos/vos_3.tiles/preview.jpg" /> <image> <cube url="../../../vosbergen/mobile/panos/vos_3.tiles/pano_%s.jpg" /> <mobile> <cube url="../../../vosbergen/mobile/panos/vos_3.tiles/mobile_%s.jpg" /> </mobile> </image> <hotspot name="hs3_2" style="skin_hotspotstyle_black" ath="-1.1425375474639026" atv="13" linkedscene="scene_vos_2" /> </scene> <include url="aircompass/aircompass.xml" /> <plugin name="skin_gyro" url="../skin/plugins/gyro.js" keep="true" enabled="true" camroll="true" friction="0.5" velastic="0" devices="mobile|tablet" /> <plugin name="compass" devices="html5" url="../skin/plugins/compass.js" compassenabled="true" keep="true" heading="50" onavailability="if(compassenabled == true, copy(view.hlookat, heading););" onchange="if(compassenabled == true, copy(view.hlookat, heading););" /> <evens name="compass" keep="true" onnewpano="if(plugin[compass].available, copy(view.hlookat, heading));" /> <style name="spot_style" url="../skin/buttons/mappoint2.png" keep="true" zorder="50" /> <action name="setmapspots"> map_vars(); txtadd(mapsptsx, '_spot', get(scene[get(xml.scene)].title), 'x'); copy(mapsptsx, get(mapsptsx)); txtadd(mapsptsy, '_spot', get(scene[get(xml.scene)].title), 'y'); copy(mapsptsy, get(mapsptsy)); txtadd(mapsptsh, '_spot', get(scene[get(xml.scene)].title), 'h'); copy(mapsptsh, get(mapsptsh)); set(plugin[spotx].x, get(mapsptsx)); set(plugin[spotx].y, get(mapsptsy)); add(mapsptsxm, mapsptsx,7); add(mapsptsym, mapsptsy,7); set(plugin[radar].x, get(mapsptsxm)); set(plugin[radar].y, get(mapsptsym)); set(plugin[radar].heading, get(mapsptsh)); </action> <layer name="map" url="../skin/buttons/map_sat.png" scale="0.5" keep="true" align="lefttop" x="10" y="10" visible="true" > <layer name="radar" url="../skin/plugins/radar.js" parent="map" zorder="5" origin="lefttop" edge="center" keep="true" scale="1.8" x="get(_spot1x);" y="get(_spot1y);" width="80" height="80" linewidth="2" fillalpha="0.5" fillcolor="0x000000" /> <layer name="spotx" url="../skin/buttons/mappointactive3.png" parent="map" visible="true" keep="true" zorder="100" origin="lefttop" x="get(_spot1x);" y="get(_spot1y);" /> <layer name="spot1" style="spot_style" x="get(_spot1x)" y="get(_spot1x)" onclick="loadscene(scene_huis_1),null,MERGE,BLEND(1));" onloaded="set(x,get(_spot1x));set(y,get(_spot1y));" /> <layer name="spot2" style="spot_style" x="get(_spot2x)" y="get(_spot2x)" onclick="loadscene(scene_vos_2),null,MERGE,BLEND(1));" onloaded="set(x,get(_spot2x));set(y,get(_spot2y));" /> <layer name="spot3" style="spot_style" x="get(_spot3x)" y="get(_spot3x)" onclick="loadscene(scene_vos_3),null,MERGE,BLEND(1));" onloaded="set(x,get(_spot3x));set(y,get(_spot3y));" /> </layer> <action name="map_vars"> set(_spot1x, 212); set(_spot1y, 149); set(_spot1h, 198); set(_spot2x, 180); set(_spot2y, 146); set(_spot2h, 20); set(_spot3x, 160); set(_spot3y, 138); set(_spot3h, 15); </action> <progress showload="none" showwait="none" /> <!-- Skin Layout --> <layer name="skin_btn_compass" url="../skin/buttons/btn_compass.png" keep="true" align="bottom" devices="HTML5" visible="true" x="-100" scale="0.5" ondown="if(plugin[compass].compassenabled == true, set(plugin[compass].compassenabled,false);set(plugin[skin_gyro].enabled,false);, set(plugin[compass].compassenabled,true);set(plugin[skin_gyro].enabled,true); );" /> <layer name="skin_btn_gyro" url="../skin/buttons/btn_gyro.png" keep="true" align="bottom" visible="true" devices="HTML5" x="140" scale="0.5" ondown="switch(plugin[skin_gyro].enabled);" /> <!-- Skin Hotspot Style (the hotspots need a 'linkedscene' attribute to be clickable)--> <style name="skin_hotspotstyle_black" url="../skin/buttons/htsp_black.png" id="hotsp" alpha="0.6" scale="1" edge="top" oy="0" zoom="false" distorted="true" onclick=" setmovevar(); if(linkedscene, tween(scale,0.25,0.5); tween(oy,-50,0.5); tween(alpha,0,0.5,,WAIT); tween(view.vlookat,0,0.5, easeOutQuad); tween(view.fov,40,0.5, easeOutQuad); wait(1); loadscene(get(linkedscene),null,MERGE,BLEND(1)); ); wait(0.3); getmovevar(); " /> <action name="lookinterrupt"> breakall(); </action> <action name="setmovevar"> set(_movevar, get(scene[get(xml.scene)].title)); </action> <action name="getmovevar"> set(_newmovevar, get(scene[get(xml.scene)].title)); if(_movevar == 1, if(_newmovevar == 2, lookat(0,0);wait(1);oninterrupt( action(lookinterrupt) );lookto(180,0,70,smooth(25,25,25)); ); ); if(_movevar == 2, if(_newmovevar == 1, lookat(20,0);wait(1);oninterrupt( action(lookinterrupt) );lookto(270,0,70,smooth(25,25,25)); ); if(_newmovevar == 3, lookat(0,0);wait(1);oninterrupt( action(lookinterrupt) );lookto(270,0,70,smooth(25,25,25)); ); ); if(_movevar == 3, if(_newmovevar == 2, lookat(180,0);wait(1);oninterrupt( action(lookinterrupt) );lookto(0,0,70,smooth(25,25,25)); ); ); </action> </krpano> |
This post has been edited 6 times, last edit by "Tuur" (Sep 27th 2012, 3:28am)
Location: Netherlands
Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer
![]() |
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 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 |
<krpano logkey="true" onstart="startup();" > <include url="aircompass/aircompass.xml" /> <action name="startup"> if(startscene === null, copy(startscene,scene[0].name)); loadscene(get(startscene), null, MERGE); </action> <scene name="scene_huis_1" title="1" onstart="" thumburl="panos/huis_1.tiles/thumb.jpg" heading=""> <view hlookat="0" vlookat="0" fovtype="MFOV" fov="70" maxpixelzoom="2.0" fovmin="30" fovmax="120" limitview="auto" /> <include url="aircompass/aircompass.xml" /> <preview url="../../../vosbergen/mobile/panos/huis_1.tiles/preview.jpg" /> <image> <cube url="../../../vosbergen/mobile/panos/huis_1.tiles/pano_%s.jpg" /> <mobile> <cube url="../../../vosbergen/mobile/panos/huis_1.tiles/mobile_%s.jpg" /> </mobile> </image> </scene> <plugin name="skin_gyro" url="../skin/plugins/gyro.js" keep="true" enabled="true" camroll="true" friction="0.5" velastic="0" devices="mobile|tablet" /> <plugin name="compass" devices="html5" url="../skin/plugins/compass.js" compassenabled="true" keep="true" onavailability="if(compassenabled == true, copy(view.hlookat, heading););" onchange="if(compassenabled == true, copy(view.hlookat, heading););" /> <evens name="compass" keep="true" onnewpano="if(plugin[compass].available, copy(view.hlookat, heading));" /> <!-- map stuff --> <style name="spot_style" url="../skin/buttons/mappoint2.png" keep="true" zorder="50" /> <layer name="map" url="../skin/buttons/map_sat.png" scale="0.5" keep="true" align="lefttop" x="10" y="10" visible="true" > <layer name="radar" url="../skin/plugins/radar.js" parent="map" zorder="5" origin="lefttop" edge="center" keep="true" scale="1.8" x="217" y="155" heading="198" width="80" height="80" linewidth="2" fillalpha="0.5" fillcolor="0x000000" /> <layer name="spotx" url="../skin/buttons/mappointactive3.png" parent="map" visible="true" keep="true" zorder="100" origin="lefttop" x="212" y="149" /> <layer name="spot1" style="spot_style" x="212" y="149" onclick="loadscene(scene_huis_1),null,MERGE,BLEND(1));" /> </layer> <!-- buttons to show the problem of: when put off gyro and compass. Then put on gyro and when you change to compass gyro goes off.. --> <layer name="skin_btn_compass" url="../skin/buttons/btn_compass.png" keep="true" align="bottom" devices="HTML5" visible="true" x="-100" scale="0.5" ondown="if(plugin[compass].compassenabled == true, set(plugin[compass].compassenabled,false);set(plugin[skin_gyro].enabled,false);, set(plugin[compass].compassenabled,true);set(plugin[skin_gyro].enabled,true); );" /> <layer name="skin_btn_gyro" url="../skin/buttons/btn_gyro.png" keep="true" align="bottom" visible="true" devices="HTML5" x="140" scale="0.5" ondown="switch(plugin[skin_gyro].enabled);" /> </krpano> |
This post has been edited 5 times, last edit by "Tuur" (Sep 27th 2012, 2:45pm)
Location: Netherlands
Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer