Thanks for your answer,
spacerywirtualne
But i'm still cannot fire a videoplayback-related events, so im likely need your help again.
Here is my xml config:
|
Quellcode
|
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
|
<krpano>
<action name="startup" autorun="onstart">
if(device.panovideosupport == false,
error('Sorry, but panoramic videos are not supported by your current browser!');
,
loadscene(videopano);
);
</action>
<scene name="videopano" title="krpano Panoramic Video Example">
<!-- include the videoplayer interface / skin (with VR support) -->
<include url="skin/videointerface.xml" />
<!-- include the videoplayer plugin -->
<plugin name="video"
url.html5="/static/krpano/viewer/plugins/videoplayer.js"
pausedonstart="true"
loop="false"
volume="1.0"
onloaded="add_video_sources();"
onvideoready="jscall('alert(123);')"
onvideoplay="jscall(alert(123);)"
onvideopaused="js('alert(123);')"
onvideocomplete="js(alert(123);)"
onerror="jscall('alert(123);')"
/>
<!-- use the videoplayer plugin as panoramic image source -->
<image>
<sphere url="plugin:video" />
</image>
<!-- set the default view -->
<view hlookat="0" vlookat="0" fovtype="DFOV" fov="130" fovmin="75" fovmax="150" distortion="0.0" />
<!-- add the video sources and play the video -->
<action name="add_video_sources">
videointerface_addsource('1024x512', '%CURRENTXML%/video-1024x512.mp4|%CURRENTXML%/video-1024x512.webm|%CURRENTXML%/iphone-audio.m4a', '%CURRENTXML%/video-1024x512-poster.jpg');
videointerface_addsource('1920x960', '%CURRENTXML%/video-1920x960.mp4|%CURRENTXML%/video-1920x960.webm|%CURRENTXML%/iphone-audio.m4a', '%CURRENTXML%/video-1920x960-poster.jpg');
if(device.ios,
<!-- iOS Safari has a very slow 'video-to-webgl-texture' transfer, therefore use a low-res video by default -->
videointerface_play('1024x512');
,
videointerface_play('1920x960');
);
</action>
</scene>
</krpano>
|
The other functionality - play and changing viewpoint - works fine. But js events are still not fired, regardless if i try to set them in a hardcode way like show above, or trying to call function available as window.kr_eventHandler()
Id just tried both js() and jscall, quoting argument and not - im just out of ideas what i miss.
Chrome debug console is clear at any cases.
Any suggestions what should I try to change?