Hi,
I am trying to implement video transitions between different scenes. I already got it working by creating a layer outside the scenes in following way:
<layer name="video"
url.html5="plugins/videoplayer.js"
url.flash="pugins/videoplayer.swf"
videourl="gehen.mp4"
align="center" x="0" y="0"
width="100%" height="prop"
pausedonstart="true"
keep="true"
alpha="0"
visible="false"
enabled="false"
loop="false"
volume="1.0"
onvideoready=""
onvideoplay=""
onvideopaused=""
onvideocomplete="tween(layer[video].alpha, 0, 1); delayedcall(2, set(layer[video].visible, false));"
onerror=""
/>
Display More
And within the scene I create a hotspot, which calls an action to set the video active, play the video and change to the next scene in the background of the video. This also works fine with the following code:
<hotspot name="videotest" url="skin/vtourskin_hotspot.png" ath="-20.205" atv="32.860" onclick="video_blend();" />
<action name="video_blend">
set(layer[video].visible, true);
layer[video].play();
tween(layer[video].alpha, 1, 1);
loadscene(scene_Standpunkt_2_edit, null, MERGE, NOBLEND);
</action>
Now in the next scene I would like to use
to update the video url for the next transition (that is from scene 2 to scene 3 for example). However this doesn´t seem to work. If I call the action to play the video after updating the video url it still uses the first video and not the new one with the updated url. Is set(layer[video].videourl, new_url.mp4); possible to use?
If it´s not possible, what could be a workaround? I thought about creating a bunch of video layers in the beginning and then later use the one I need for my transition as I did above. However I´m not sure if these many layers will affect the performance of my tour when I a need a lot of different transition videos (although they are set to visible="false" and enabled="false").
It would be great to hear your oppinion and suggestions.
Regards
Martin