You are not logged in.

1

Sunday, January 24th 2016, 8:32am

vr with 360 videos

Hi all,

I am trying to build a vr virtual tour using 360 videos. I know of the touch problem for auto playing videos on mobile, for that matter, my first video is triggered when touching the ENTER VR button, and everything is fine. The problem comes when passing from one video to another, which is done inside the VR interface, where no touching is possible (the phone is in the cardboard). Videos don't play at all unless the screen receives a touch event. I can't find a solution with android devices. Is there any?

2

Sunday, January 24th 2016, 3:53pm

Hi,

this will be possible with the next krpano release.

Best regards,
Klaus

3

Sunday, January 24th 2016, 7:49pm

thanks Klaus, that's really good news

any hint on availability?

4

Thursday, February 4th 2016, 11:27am

vr 30 video

Hi to everyone,
i have the same problem to solve (vr 360 video) and i'm trying krpano 1.19 prerelease3.
But with the panoramic video i see only a black screen:
To try this, you can open with Chrome (on an Android Smartphone) this link (krpano demo):
http://d8d913s460fub.cloudfront.net/krpa…x.html?v=119pr3

if I select panoramic video (the 3rd demo) i see only black screen (with Galaxy Note 4 and Chrome browser).

I'have downloaded krpano and i have created an Android project to open the files in a local web view, but i have the same result (black screen on panoramic video).

Is there the old but big problem with Chromium web view (and is there any solution)?
Thank's for all your opinion about this and sorry for my bad english.

Antonio Mazzeo

KiboOst

Trainee

Posts: 83

Location: France

Occupation: TD

  • Send private message

5

Thursday, February 4th 2016, 12:10pm

I have no problem autoplaying videos on iOS / Android ?

Source code

1
2
3
4
5
6
7
8
9
10
11
<plugin name="video" url.flash="%SWFPATH%/plugins/videoplayer.swf" url.html5="%SWFPATH%/plugins/videoplayer.js"
            	posterurl=""
            	videourl.desktop=""
            	videourl.tablet=""
            	videourl.mobile=""

            	pausedonstart="true"

            	onloaded="videointerface_setup_interface(get(name)); setup_video_controls();"
            	onvideoready="videointerface_videoready(); videointerface_togglepause();"
    	/>

Tuur

Sage

Posts: 3,113

Location: Netherlands

Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Send private message

6

Thursday, February 4th 2016, 2:47pm

http://www.virtualtuur.com
Skype:studiotuur

7

Thursday, February 4th 2016, 3:16pm

Thanks Tuur (and thanks kiboOst) for the answers.
I'have enabled #ignore-gpu-blacklist on Chrome and i have solved using Chrome Browser.
Now the problem is i should make an Android app with KRPano but in this case i have black screen again (only for the 3rd video demo).
The Android Studio Console shows this error:


GL ERROR :GL_INVALID_OPERATION : glCreateAndConsumeTextureCHROMIUM: invalid target
02-04 15:14:34.948 30918-31110/? E/chromium: [ERROR:gles2_cmd_decoder.cc(12937)] [GroupMarkerNotSet(crbug.com/242999)!:54B471AE]GL ERROR :GL_INVALID_VALUE : glCopyTextureChromium: source texture has no level 0
02-04 15:14:34.958 30918-31110/? E/chromium: [ERROR:gles2_cmd_decoder.cc(7430)] [GroupMarkerNotSet(crbug.com/242999)!:54B471AE]RENDER WARNING: texture bound to texture unit 0 is not renderable. It maybe non-power-of-2 and have incompatible texture filtering.

Any idea about this?

Many thanks,
Antonio

8

Friday, February 26th 2016, 2:48pm

This is something we really really do need at the moment. We want to show multiple videos in our application through the VR interface.

There is a workaround in the current krpano for single videos. I wonder, if we can extend this hack to load, pause and hide all videos in the tour. Could this work?

Hi,

this will be possible with the next krpano release.

Best regards,
Klaus

Tuur

Sage

Posts: 3,113

Location: Netherlands

Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Send private message

9

Friday, February 26th 2016, 2:52pm

Use scenes!
Don't pause video, just change videofile onstart new scene.
With the floating vr menu , when you look a bit down , should work.
For me it does.
Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

This post has been edited 1 times, last edit by "Tuur" (Feb 26th 2016, 3:05pm)


10

Friday, February 26th 2016, 3:26pm

So we never should pause a video once we hit enter VR button, (and change the video file via plavideo() ?). But we also have static scenes in the tour. Would this effect performance, since it's running on a mobile phone?

Tuur

Sage

Posts: 3,113

Location: Netherlands

Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Send private message

11

Friday, February 26th 2016, 3:28pm

Not sure when in combination with static scenes.
Could be problematic in that case.
Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

12

Friday, February 26th 2016, 3:40pm

Okay I'll give it a try, we have a tight deadline so we're out of options. I hope v19 is released soon!

Tuur

Sage

Posts: 3,113

Location: Netherlands

Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Send private message

13

Friday, February 26th 2016, 3:49pm

i can imagine some workarounds, but never tried/tested.
Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

ChrisR

Beginner

Posts: 9

Location: Brooklyn

  • Send private message

14

Wednesday, March 16th 2016, 8:05pm

Hi - I've been trying to figure out the way around the required touch to start playing videos as referenced by Tuur. I have not been successful. *sad*
I'm using playvideo(), scenes, and have created an action that is called onstart of the scene. The video plugin is loaded prior to entering the first scene.

Since I am still fairly new to xml there is big chance I made a mistake in the syntax. Below is the code I'm using showing only the relevant parts of a much larger file.
Any help on this would be greatly appreciated, even if the answer is: "stop wasting your time now and wait for the next krpano release." *smile*
(At least I can then give our client a firm answer.) *smile*

Many thanks in advance
Chris

<krpano version="1.19" title="Touch Work Around" >
[...]

<plugin name="video1"
url.flash="plugins/videoplayer.swf"
url.html5="plugins/videoplayer.js"
videourl=""
posterurl=""
pausedonstart="false"
loop="true"
preferredformat=""
buffertime="0.1"
ignoremetadata="false"
volume="1.0"
onvideoready=""
onvideoplay=""
onvideopaused=""
onvideocomplete=""
onerror=""
preload="true"
keep="true"
/>

<action name="vidScene01">
plugin[video1].playvideo('videos/Scene01.mp4', 'videos/Poster_Scene01.jpg');
</action>

<scene name="Scene01" title="..." onstart="vidScene01(); ..." thumburl="panos/Scene01/thumb.jpg" lat="" lng="" heading="">

<view hlookat="270" vlookat="0" fovtype="MFOV" fov="100" maxpixelzoom="" fovmin="100" fovmax="100" limitview="auto" />

<image hfov="360" vfov="180">
<sphere url="plugin:video1" />
</image>

</scene>

[...]

</krpano>

Goofyfooter

Beginner

Posts: 1

Location: Australia

Occupation: Photographer

  • Send private message

15

Wednesday, May 11th 2016, 1:55am

Hi all,
This has been a very helpful post. Thanks!
I have been trying to build a 360 video app using Phonegap. I am using the following xml code to automatically enter VR mode and start the video.
This works perfectly in a Chrome browser on both Windows desktop and Android mobile device. (Android 4.4.2)
Please note that all objects are in the same root directory for Phonegap app build, hence no "%SWFPATH%'" references...

Source code

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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
<krpano>
   <action name="startup" autorun="onstart">
      loadscene(videopano);
   </action>
   <plugin name="video" keep="true"
      url.flash="videoplayer.swf"
      url.html5="videoplayer.js"
      volume="1.0"
      videourl.ios="videoname-540p.mp4"
      videourl.no-ios="videoname-720p.mp4"
      posterurl="videoname.jpg"
      pausedonstart="true"
      loop="false"
      panovideo="true"
      />
   <plugin name="gyro" keep="true"    
      url="gyro2.js"     
      devices="html5.and.touch"      
      enabled="true"
      />

   <!-- ensure stagescale 2x for mobile devices (regardless if mobilescale is 0.5 or 1.0) -->
   <krpano stagescale="calc:stagescale*(1.0 + 1.0*(stagescale LT 1.0))" devices="mobile" />

   <!-- include VR support -->
   <include url="webvr.xml" />

   <!-- overwrite some settings from the webvr.xml -->
   <plugin name="WebVR" keep="true"
      mobilevr_fake_support="true"
      mobilevr_support="true"
      onavailable="removelayer(webvr_enterbutton); webvr_onavailable();"
      onentervr="webvr_onentervr(); webvr_setup();"
      onexitvr="webvr_onexitvr(); webvr_setup();"
      />

   <action name="webvr_setup">
      if(webvr.isenabled,
      set(display.hotspotrenderer, webgl);
      set(skin_settings.loadscene_flags, MERGE|KEEPVIEW|KEEPMOVING);
      webvr_act_as_gyro_in_portrait_mode();
      set(hotspot[exit].visible, true);
      ,
      set(display.hotspotrenderer, auto);
      set(skin_settings.loadscene_flags, MERGE);
      tween(layer[webvr_rotate_to_landscape_request].alpha, 0.0, 0.0);
      set(hotspot[exit].visible, false);
      );
   </action>

   <!-- show a 'rotate the device' info when the mobile device is in portrait mode in VR mode -->
   <layer name="webvr_rotate_to_landscape_request" keep="true" vr="true" devices="mobile"
      url="rotate_device.png" scale="0.5"
      align="top" edge="center" y="28%" autoalpha="true" alpha="0.0"
      enabled="false"
      />
   <action name="webvr_act_as_gyro_in_portrait_mode">
      if(device.mobile AND webvr.isenabled,
         div(aspect, stagewidth, stageheight);
         if(aspect != lastaspect OR '%1' == 'true', copy(lastaspect, aspect);
         if(stagewidth GT stageheight,
            <!-- landscape mode - use stereo rendering and a direct/fast gyro sensor mode -->
	    set(display.stereo, true);
	    set(webvr.mobilevr_sensor_mode, 3);
	    tween(layer[webvr_rotate_to_landscape_request].alpha, 0.0, 0.0);
	    ,
            <!-- portrait mode - use normal rendering and a smoother/slower gyro sensor mode -->
	    set(display.stereo, false);
	    set(webvr.mobilevr_sensor_mode, 1);
	    tween(layer[webvr_rotate_to_landscape_request].alpha, 1.0);
            delayedcall(3.0, tween(layer[webvr_rotate_to_landscape_request].alpha, 0.0, 1.0); );
	    );
	  );
	  ,
	  set(lastaspect, 0);
        );
   </action>
   <events name="webvr_events" keep="true" onresize.mobile="webvr_act_as_gyro_in_portrait_mode();" onviewchange="" />

   <!-- show an 'exit' hotspot near the nadir in VR mode -->
   <style name="webvr_style" depth="800" scale="0.7" distorted="true" ath="180" atv="80" alpha="1.0" zorder="99" />
   <hotspot name="exit" keep="true" style="webvr_style" url="exit_button.png" onover="tween(scale,0.6);" onout="tween(scale,0.5);" vr_timeout="2000"
            onclick="plugin[video].pause();webvr.exitVR();" visible="false"/>

   <scene name="videopano">
      <layer name="black_bg" type="container" bgcolor="0x000000" bgalpha="1" width="100%" height="100%" align="center">
         <layer name="start_button" url="start_button.png" align="center" onclick="webvr.enterVR();removelayer(start_button);plugin[video].play();"/>
      </layer>
      <image><sphere url="plugin:video"/></image>
      <view hlookat="-130" vlookat="10" fovtype="DFOV" fov="110" fovmin="70" fovmax="150" distortion="0.0"/>
   </scene>
</krpano>


However, when using Phonegap Dev on Android I only get the BLACK SCREEN with sound. *wacko*
Seems strange that it works ok in the browser but not when using the Android webview.
Is this still an Android bug or am I missing something????


Any help is much appreciated *smile*
Thanks in advance.



(Background info: I have specified mobilevr_support="true" in my code above to override any webvr restrictions.)
I have also downloaded several 360 video apps from the Google Play store, including the JAUNT series (featuring Paul McCartney, Jack White & The North Face) and a Mercedes Benz demo by Visualise. These all work fine - how do they do it? If they use webvr then why does this not work for us? *confused*


*** SOLVED ***
Crosswalk plugin fixes it! https://github.com/crosswalk-project/cor…osswalk-webview
Now I can put all of my panos/videos into phone apps.
Thanks Klaus - KRpano is a wonderful product.

This post has been edited 2 times, last edit by "Goofyfooter" (May 15th 2016, 10:42am)


Posts: 7

Location: Los Angeles

Occupation: Developer @ wildlife.la

  • Send private message

16

Friday, May 13th 2016, 1:49am

@ecasasin You'll want to invoke the autostart for all the videos you wish to play.

Something like this:


Source code

1
2
3
4
<layer name="webvr_enterbutton"
align="bottom" y="10%"
ondown="video_auto_start(); video2_auto_start();"
/>



By doing the above, I was able to play both videos in the VR interface by looking at each hotspot through my cardboard. However, when I try to play any of the videos more than once, I run into the @Goofyfooter issue where the video will play the audio, but only display a black screen.