![]() |
|
|
|
|
|
||||||||||
|
| User list | Rules | You are not logged in.
Pages: 1
Bonjour à toutes et tous,
je suis en train de perdre patience sur un petit problème:
- ma visite comprend 4 panos avec un plan
- j'ai ajouté pour chaque pano (donc dans chaque xml correspondant) un menu déroulant (utilisant le plugin combobox) me permettant d'appeler des photos
- mon code est évidemment exactement le même pour chaque menu déroulant sauf les url correspondant aux photos
- j'ai ajouté la fonction zorder pour que mes photos s'affichent par dessus le plan quand celui-ci est ouvert
- tout fonctionne correctement sauf pour le premier pano: le nom des hotspots du plan ne s'affichent pas, seul "Fermer le plan", qui devrait s'afficher partout sur le plan sauf sur les hotpots, s'affiche (cf xml joint) !
<!--************** Plan ***********************************************************************-->
<plugin name="map" url="Trucheredata/map/map.jpg" keep="true" align="lefttop" x="10" y="10" width="40" height="40" handcursor="false" onhover="showtext(Ouvrir le Plan)" onloaded="hidemapspot();" onclick="openmap"/>
<plugin keep="true" visible="false" name="mapspot0" onclick="mainloadpano(Truchere1.xml);" url="Trucheredata/graphics/spots/spot0.png" blingCounter="0" onhover="showtext(Entrée de la dune); set(textstyle[DEFAULT].background, true); set(textstyle[DEFAULT].fontsize, 14); set(textstyle[DEFAULT].textcolor, 0xffffffff); set(textstyle[DEFAULT].backgroundcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0x000000,4,2));" onout="set(textstyle[DEFAULT].background, false); set(textstyle[DEFAULT].fontsize, 18); set(textstyle[DEFAULT].textcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0xffffffff,4,4));" align="lefttop" edge="center" parent="map" x="43.3678%" y="22.6036%" width="2%" height="prop"/>
<plugin keep="true" visible="false" name="mapspot1" onclick="mainloadpano(Truchere3.xml);" url="Trucheredata/graphics/spots/spot0.png" blingCounter="0" onhover="showtext(La Tourbière); set(textstyle[DEFAULT].background, true); set(textstyle[DEFAULT].fontsize, 14); set(textstyle[DEFAULT].textcolor, 0xffffffff); set(textstyle[DEFAULT].backgroundcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0x000000,4,2));" onout="set(textstyle[DEFAULT].background, false); set(textstyle[DEFAULT].fontsize, 18); set(textstyle[DEFAULT].textcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0xffffffff,4,4));" align="lefttop" edge="center" parent="map" x="35.0894%" y="23.432%" width="2%" height="prop"/>
<plugin keep="true" visible="false" name="mapspot2" onclick="mainloadpano(Truchere2.xml);" url="Trucheredata/graphics/spots/spot0.png" blingCounter="0" onhover="showtext(La dune); set(textstyle[DEFAULT].background, true); set(textstyle[DEFAULT].fontsize, 14); set(textstyle[DEFAULT].textcolor, 0xffffffff); set(textstyle[DEFAULT].backgroundcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0x000000,4,2));" onout="set(textstyle[DEFAULT].background, false); set(textstyle[DEFAULT].fontsize, 18); set(textstyle[DEFAULT].textcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0xffffffff,4,4));" align="lefttop" edge="center" parent="map" x="40.0753%" y="28.7574%" width="2%" height="prop"/>
<plugin keep="true" visible="false" name="mapspot3" onclick="mainloadpano(Truchere0.xml);" url="Trucheredata/graphics/spots/spot0.png" blingCounter="0" onhover="showtext(Étang);set(textstyle[DEFAULT].background, true); set(textstyle[DEFAULT].fontsize, 14); set(textstyle[DEFAULT].textcolor, 0xffffffff); set(textstyle[DEFAULT].backgroundcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0x000000,4,2));" onout="set(textstyle[DEFAULT].background, false); set(textstyle[DEFAULT].fontsize, 18); set(textstyle[DEFAULT].textcolor, 0x000000); set(textstyle[DEFAULT].effect, dropshadow(0,45,0xffffffff,4,4));" align="lefttop" edge="center" parent="map" x="83.4431%" y="38.2249%" width="2%" height="prop"/>
<plugin name="mapradar" parent="map" edge="center" align="lefttop" keep="true" url="Trucheredata/map/radar.swf" visible="false" width="56" height="56" linecolor="0xffffff" linealpha="0.666667" linewidth="2" fillcolor="0xFF0000" fillalpha="0.8"/>
<action name="showmapspot">
set( plugin[mapspot0].alpha , 0);
set( plugin[mapspot0].visible, true);
tween(plugin[mapspot0].alpha , 1);
set( plugin[mapspot1].alpha , 0);
set( plugin[mapspot1].visible, true);
tween(plugin[mapspot1].alpha , 1);
set( plugin[mapspot2].alpha , 0);
set( plugin[mapspot2].visible, true);
tween(plugin[mapspot2].alpha , 1);
set( plugin[mapspot3].alpha , 0);
set( plugin[mapspot3].visible, true);
tween(plugin[mapspot3].alpha , 1);
</action>
<action name="hidemapspot">
set(plugin[mapspot0].visible,false);
set(plugin[mapspot1].visible,false);
set(plugin[mapspot2].visible,false);
set(plugin[mapspot3].visible,false);
</action>
<!-- fermeture du plan -->
<action name="closemap">
set(plugin[mapradar].visible,false);
hidemapspot();
set(plugin[map].onclick,openmap);
set(plugin[map].onhover,showtext(Ouvrir le Plan));
set(plugin[map].width, 40);
set(plugin[map].height, 40);
</action>
<!-- ouverture du plan -->
<action name="openmap">
if(plugin[mapradar].shouldbevisible == true, set(plugin[mapradar].visible,true););
set(plugin[map].onclick, closemap);
set(plugin[map].onhover,showtext(Fermer le Plan));
set(plugin[map].height, prop);
tween(plugin[map].width, 35%, 0.5, easeoutquad, showmapspot(););
set(plugin[map].align, lefttop);
set(plugin[map].x , 10);
set(plugin[map].y , 10);
</action>
<!-- Désélectionne tous les spot de la cartes sauf celui passé en argument -->
<!-- Désélectionne tous les spot de la carte si aucun argument n'est fourni -->
<action name="unselectmapspotsbutpassed">
set(plugin[mapradar].visible , false);
set(plugin[mapradar].shouldbevisible, false);
if (%1 != mapspot0,
if(plugin[mapspot0].animated,
set(plugin[mapspot0].frame , 0);
set(plugin[mapspot0].ypos , 0);
set(plugin[mapspot0].animationCounter, 0)
txtadd(plugin[mapspot0].crop,'0|0|',get(plugin[mapspot0].framewidth),'|',get(plugin[mapspot0].frameheight));
,
set(plugin[mapspot0].blingCounter, 0)
)
);
resetmapspot(mapspot0);
if (%1 != mapspot1,
if(plugin[mapspot1].animated,
set(plugin[mapspot1].frame , 0);
set(plugin[mapspot1].ypos , 0);
set(plugin[mapspot1].animationCounter, 0)
txtadd(plugin[mapspot1].crop,'0|0|',get(plugin[mapspot1].framewidth),'|',get(plugin[mapspot1].frameheight));
,
set(plugin[mapspot1].blingCounter, 0)
)
);
resetmapspot(mapspot1);
if (%1 != mapspot2,
if(plugin[mapspot2].animated,
set(plugin[mapspot2].frame , 0);
set(plugin[mapspot2].ypos , 0);
set(plugin[mapspot2].animationCounter, 0)
txtadd(plugin[mapspot2].crop,'0|0|',get(plugin[mapspot2].framewidth),'|',get(plugin[mapspot2].frameheight));
,
set(plugin[mapspot2].blingCounter, 0)
)
);
resetmapspot(mapspot2);
if (%1 != mapspot3,
if(plugin[mapspot3].animated,
set(plugin[mapspot3].frame , 0);
set(plugin[mapspot3].ypos , 0);
set(plugin[mapspot3].animationCounter, 0)
txtadd(plugin[mapspot3].crop,'0|0|',get(plugin[mapspot3].framewidth),'|',get(plugin[mapspot3].frameheight));
,
set(plugin[mapspot3].blingCounter, 0)
)
);
resetmapspot(mapspot3);
</action>
<!-- Séléctionne un spot de la carte en particulier -->
<action name="selectmapspot">
unselectmapspotsbutpassed(%1);
if(plugin[%1].animated,
inc(plugin[%1].animationCounter, 1);
if(plugin[%1].animationCounter == 1,
animatemapspot(%1, 0.1);
);
,
inc(plugin[%1].blingCounter,1);
if(plugin[%1].blingCounter == 1,
blingmapspot(%1);
);
);
copy(plugin[mapradar].x , plugin[%1].x);
copy(plugin[mapradar].y , plugin[%1].y);
set( plugin[mapradar].heading , %2 );
set( plugin[mapradar].shouldbevisible, true );
if(plugin[map].onclick == closemap, set(plugin[mapradar].visible,true););
</action>
<!-- anime le spot quand il est actif (appel récursif) -->
<action name="blingmapspot">
tween(plugin[%1].alpha, 0.0, 0.8, easeInSine );
tween(plugin[%1].scale, 1.5, 0.8, easeOutCubic);
tween(, , 0.8, , resetmapspot(%1);
if(plugin[%1].blingCounter > 0, blingmapspot(%1);););
</action>
<action name="resetmapspot">
set(plugin[%1].scale,1);
set(plugin[%1].alpha,1);
</action>
<!-- Raise sequence stopper and wait sequence time to break the delayed calls -->
<action name="interruptAnimation">
ifnot (stopSequence === undefined,
set(stopSequence, true);
wait(0);
);
</action>- si je n'utilise pas la fonction zorder (même uniquement sur le xml correspondant au premier pano), le nom de chaque hotspot du plan s'affiche correctement, mais mes photos sont en arrière-plan (c'est le cas de le dire) > voir 2ème xml.
<!-------------------------------------------AJOUTS MANUELS---------------------------------------------->
<!-- combobox plugin pour le choix des photos -->
<plugin name="box_photos" url="Trucheredata/graphics/combobox.swf"
width="150" align="righttop" x="10" y="45"
onloaded="action(setup_box_photos);"
/>
<action name="setup_box_photos">
additem(Informations :, action(hide_all));
additem(Canard souchet, action(closeallobjects); action(show_photo1) );
additem(Trèfle d eau, action(closeallobjects); action(show_photo2) );
additem(Fuligule milouin, action(closeallobjects); action(show_photo3) );
additem(Hottonie des marais, action(closeallobjects); action(show_photo4) );
</action>
<!-- declaration des photos fixes -->
<!-- On change dans plugin le "name" et "url" ; dans action le "name" et "set(plugin[]" -->
<!-- photo 1 -->
<plugin name="photo1" url="Trucheredata/graphics/spots/object0.jpg" preload="false" keep="true" align="center" edge="center" width="40%" height="prop" visible="false" scale="1" smoothing="true" onclick="set(visible,false); plugin[box_photos].selectitem(Informations :);" />
<action name="show_photo1">
set(plugin[photo1].visible,true);
set(plugin[photo2].visible, false);
set(plugin[photo3].visible, false);
set(plugin[photo4].visible, false);
set(autorotate.enabled,false);
</action>
<!-- photo 2 -->
<plugin name="photo2" url="Trucheredata/graphics/spots/object1.jpg" preload="false" keep="true" align="center" edge="center" width="55%" height="prop" visible="false" scale="1" smoothing="true" onclick="set(visible,false); plugin[box_photos].selectitem(Informations :);" />
<action name="show_photo2">
set(plugin[photo1].visible,false);
set(plugin[photo2].visible, true);
set(plugin[photo3].visible, false);
set(plugin[photo4].visible, false);
set(autorotate.enabled,false);
</action>
<!-- photo 3 -->
<plugin name="photo3" url="Trucheredata/graphics/spots/object2.jpg" preload="false" keep="true" align="center" edge="center" width="50%" height="prop" visible="false" scale="1" smoothing="true" onclick="set(visible,false); plugin[box_photos].selectitem(Informations :);" />
<action name="show_photo3">
set(plugin[photo1].visible,false);
set(plugin[photo2].visible, false);
set(plugin[photo3].visible, true);
set(plugin[photo4].visible, false);
set(autorotate.enabled,false);
</action>
<!-- photo 4 -->
<plugin name="photo4" url="Trucheredata/graphics/spots/object3.jpg" preload="false" keep="true" align="center" edge="center" width="35%" height="prop" visible="false" scale="1" smoothing="true" onclick="set(visible,false); plugin[box_photos].selectitem(Informations :);" />
<action name="show_photo4">
set(plugin[photo1].visible,false);
set(plugin[photo2].visible, false);
set(plugin[photo3].visible, false);
set(plugin[photo4].visible, true);
set(autorotate.enabled,false);
</action>
<!-- cacher tout-->
<action name="hide_all">
set(plugin[photo1].visible,false);
set(plugin[photo2].visible,false);
set(plugin[photo3].visible,false);
set(plugin[photo4].visible,false);
</action>
</krpano>Je pense que le conflit vient d'une fonction du plan, comme unselectmapspotsbutpassed() peut-être, mais ce que je ne comprends pas c'est pourquoi le plan ne fonctionne pas correctement uniquement sur le premier pano.
Voilà où j'en suis... si quelqu'un a une idée, même mauvaise, je suis preneur :-)
Last edited by julerty (2012-04-26 13:56:07)
Offline
Pages: 1
Powered by PunBB
© Copyright 2002–2005 Rickard Andersson
|
CHOOSING KOLOR Why choose Kolor? Which solution to choose? Download a trial Where can I buy? Education |
SOFTWARE Autopano Pro Autopano Giga Panotour Panotour Pro XnView |
ACCESSORIES Training DVD Panobook PROJECTS Paris 26 Gigapixels Yosemite 17 Gigapixels |
COMMUNITY Forums YouTube channel Google+ |
COMPANY Blog About Kolor Resellers Contact Visit us |
PRESS Press center Press review TOOLS My account |
