Hi all,
I'm trying to make a KRPano tour containing several videos (with sound) that has to run on iOS as well as other mobile and PC platforms. On iOS I have to start the application with user interaction before the video will start. Thats fine and I understand why iOS does not want its users bothered by autoplaying videos and sound. But my tour consists of several scenes and each scene needs user interaction for the video to start. Is there any (workaround) way to allow playing of the video on the start of a scene without user interaction?
Do I maybe have to change my hierarchy so the plugin lives in the root element and swap videos to prevent a new player being created? If so, how do I reference the <image> that lives in the scene?
My project setup is roughly (just the relevant parts):
<krpano>
<transition>
loadscene(%1)
</transition>
....more stuff
<scene name="scene_1">
<plugin name="video"
url.html5="%SWFPATH%/plugins/videoplayer.js"
url.flash="%SWFPATH%/plugins/videoplayer.swf"
pausedonstart="false"
autopause="true"
autoresume="true"
loop="false"
muted="true"
onloaded="add_video_sources();"
/>
<image>
<sphere url="plugin:video"/>
</image>
<action name="add_video_sources">
videointerface_addsource('2880x1440', '%CURRENTXML%/video/Intro.mp4');
videointerface_play('2880x1440');
</action>
<action name="this is called at a certain point.">
transition(scene_2);
</action>
....more stuff
</scene>
<scene name="scene_2">
<plugin name="video"
url.html5="%SWFPATH%/plugins/videoplayer.js"
url.flash="%SWFPATH%/plugins/videoplayer.swf"
pausedonstart="false"
autopause="true"
autoresume="true"
loop="false"
muted="true"
onloaded="add_video_sources();"
/>
<image>
<sphere url="plugin:video"/>
</image>
<action name="add_video_sources">
videointerface_addsource('2880x1440', '%CURRENTXML%/video/Intro.mp4');
videointerface_play('2880x1440');
</action>
<action name="this is called at a certain point.">
transition(scene_3);
</action>
</scene>
<scene name="scene_3">
<plugin name="video"
url.html5="%SWFPATH%/plugins/videoplayer.js"
url.flash="%SWFPATH%/plugins/videoplayer.swf"
pausedonstart="false"
autopause="true"
autoresume="true"
loop="false"
muted="true"
onloaded="add_video_sources();"
/>
<image>
<sphere url="plugin:video"/>
</image>
<action name="add_video_sources">
videointerface_addsource('2880x1440', '%CURRENTXML%/video/Intro.mp4');
videointerface_play('2880x1440');
</action>
<action name="this is called at a certain point.">
transition(scene_2);
</action>
</scene>
</krpano>