Hello,
I am beginner: I have get to play a background sound in my vtour, but I cannot get to show and use a button on/off fo sound like it is in the examples of krpano.
The code I am trying is:
Code
<!-- a button to pause/play the sound -->
<layer name="snd" url="soundonoff.png" align="leftbottom" x="10" y="10" alpha="0.25" scale="0.5" onover="tween(alpha,1);" onout="tween(alpha,0.25);"
crop="0|0|50|50"
onclick="pausesoundtoggle(bgsnd); switch(crop, 0|0|50|50, 0|50|50|50);"
/>
adn this is the xml I have write:
Code
<krpano version="1.20.11" title="Virtual Tour">
<include url="skin/vtourskin.xml" />
<!-- customize skin settings: maps, gyro, webvr, thumbnails, tooltips, layout, design, ... -->
<skin_settings maps="false"
maps_type="google"
maps_bing_api_key=""
maps_google_api_key=""
maps_zoombuttons="false"
maps_loadonfirstuse="true"
gyro="true"
gyro_keeplookingdirection="false"
webvr="true"
webvr_keeplookingdirection="true"
webvr_prev_next_hotspots="true"
autotour="false"
littleplanetintro="false"
followmousecontrol="false"
title="true"
thumbs="true"
thumbs_width="120" thumbs_height="80" thumbs_padding="10" thumbs_crop="0|40|240|160"
thumbs_opened="false"
thumbs_text="false"
thumbs_dragging="true"
thumbs_onhoverscrolling="false"
thumbs_scrollbuttons="false"
thumbs_scrollindicator="false"
thumbs_loop="false"
tooltips_buttons="false"
tooltips_thumbs="false"
tooltips_hotspots="false"
tooltips_mapspots="false"
deeplinking="false"
loadscene_flags="MERGE"
loadscene_blend="OPENBLEND(0.5, 0.0, 0.75, 0.05, linear)"
loadscene_blend_prev="SLIDEBLEND(0.5, 180, 0.75, linear)"
loadscene_blend_next="SLIDEBLEND(0.5, 0, 0.75, linear)"
loadingtext=""
layout_width="100%"
layout_maxwidth="814"
controlbar_width="-24"
controlbar_height="40"
controlbar_offset="20"
controlbar_offset_closed="-40"
controlbar_overlap.no-fractionalscaling="10"
controlbar_overlap.fractionalscaling="0"
design_skin_images="vtourskin.png"
design_bgcolor="0x2D3E50"
design_bgalpha="0.8"
design_bgborder="0"
design_bgroundedge="1"
design_bgshadow="0 4 10 0x000000 0.3"
design_thumbborder_bgborder="3 0xFFFFFF 1.0"
design_thumbborder_padding="2"
design_thumbborder_bgroundedge="0"
design_text_css="color:#FFFFFF; font-family:Arial;"
design_text_shadow="1"
/>
<!--
For an alternative skin design either change the <skin_settings> values
from above or optionally include one of the predefined designs from below.
-->
<!-- <include url="skin/vtourskin_design_flat_light.xml" /> -->
<!-- <include url="skin/vtourskin_design_glass.xml" /> -->
<!-- <include url="skin/vtourskin_design_ultra_light.xml" /> -->
<!-- <include url="skin/vtourskin_design_117.xml" /> -->
<!-- <include url="skin/vtourskin_design_117round.xml" /> -->
<!-- <include url="skin/vtourskin_design_black.xml" /> -->
<plugin name="soundinterface"
url.html5="plugins/soundinterface.js"
url.flash="plugins/soundinterface.swf"
preload="true"
rootpath=""
volume="1.0"
mute="false"
panningmodel="simple"
worldscale="1.0"
autopause="true"
autounlock="true"
/>
<action name="PrepareSounds" autorun="onstart">
preloadsound(sound/blur.mp3);
playsound('auto',sound/blur.mp3);
</action>
<scene name="scene_AFF_FECIT_0525" title="AFF FECIT 0525" onstart="" thumburl="panos/AFF_FECIT_0525.tiles/thumb.jpg" lat="" lng="" heading="">
<control bouncinglimits="calc:image.cube ? true : false" />
<view hlookat="0.0" vlookat="0.0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/AFF_FECIT_0525.tiles/preview.jpg" />
<image hfov="1.00" vfov="0.669421" voffset="0.00">
<flat url="panos/AFF_FECIT_0525.tiles/l%l/%v/l%l_%v_%h.jpg" multires="512,1024x686,2048x1372,3840x2572" />
</image>
</scene>
<scene name="scene_LIG_FECTI0383" title="LIG FECTI0383" onstart="" thumburl="panos/LIG_FECTI0383.tiles/thumb.jpg" lat="" lng="" heading="">
<control bouncinglimits="calc:image.cube ? true : false" />
<view hlookat="0.0" vlookat="0.0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/LIG_FECTI0383.tiles/preview.jpg" />
<image hfov="1.00" vfov="0.750000" voffset="0.00">
<flat url="panos/LIG_FECTI0383.tiles/l%l/%v/l%l_%v_%h.jpg" multires="512,768x576,1664x1248,3328x2496" />
</image>
</scene>
<scene name="scene_LIG_FECTI0385" title="LIG FECTI0385" onstart="" thumburl="panos/LIG_FECTI0385.tiles/thumb.jpg" lat="" lng="" heading="">
<control bouncinglimits="calc:image.cube ? true : false" />
<view hlookat="0.0" vlookat="0.0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="auto" />
<preview url="panos/LIG_FECTI0385.tiles/preview.jpg" />
<image hfov="1.00" vfov="0.750000" voffset="0.00">
<flat url="panos/LIG_FECTI0385.tiles/l%l/%v/l%l_%v_%h.jpg" multires="512,768x576,1664x1248,3328x2496" />
</image>
</scene>
</krpano>
Display More
Has anybody any idea of where is the problem?
Thnak a lot.