Hi all,
I would like to disable gyro while in VR mode and where do I insert the code - Tour.xml, weber.xml or vtourskin.xml.
Thanks,
DarManiac
Hi all,
I would like to disable gyro while in VR mode and where do I insert the code - Tour.xml, weber.xml or vtourskin.xml.
Thanks,
DarManiac
Hello,
What you need to do is edit the attributes onentervr and onexitvr inside the WebVR plugin which is located in the file 'webvr.xml'. But if I were you I wouldn't edit webvr.xml because you could over write it by mistake upgrading krpano.
Look the following line in tour.xml
AFTER that line (very important) write the following code:
<plugin name="WebVR" devices="html5" keep="true"
onentervr="webvr_onentervr(); set(plugin[gyro].enabled,false);"
onexitvr="webvr_onexitvr(); set(plugin[gyro].enabled,true);"
/>
WebVR plugin original code is:
<plugin name="WebVR" devices="html5" keep="true"
onentervr="webvr_onentervr();"
onexitvr="webvr_onexitvr();"
/>
So basically you're overwriting both attributes by adding some custom code. It's a bit better in my opinion.
I hope it helps,
Cheers,
ParallaxVT
Hi ParallaxVT,
Appreciate it but it doesn't seem to work. I tried adding the plugin as you directed to tour.xml first. But gyro still got enabled when I entered VR.
Also I added it to webvr.xml with the same result .
I also switched gyro to false onexitvr and onentervr for both cases and tested it. It isn't working.
Am I missing something.
Thanks,
Dar maniac
Hello,
This time I've tested it and it's actually very difficult to disable the gyro on VR Mode!
My solution doesn't work because VR Mode doesn't use the gyro plugin
I've took a look to the WebVR documentation and it doesn't mention anything about how to disable the gyro. I think the use of it it's defined inside webvr.js itself and I can't find any option to turn it off.
Sorry.
Hi,
No problem. I also had the same impression and tried to dig deep. I think Klaus might have some insight.
Thanks,
Darmaniac
Hi,
the WebVR plugin and the gyro plugin are two independent plugins - the WebVR plugin has its own gyro tracking and when the plugin is enabled it takes automatically control about the pano view. That means when the gyro plugin was enabled before that doesn't matter for the WebVR plugin.
WebVR itself without gyro tracking doesn't make sense - that's one of the core features of the plugin.
The WebVR plugin itself is mainly a package of:
What usage case do you have?
If you only want stereo rendering, this can be done also without any plugins - just enable the display.stereo setting...
Best regards,
Klaus
Hi Klaus,
The usage case that I require is that in VR mode I want to have a fixed autorotation for every scene and after it reaches a specific view, it should automatically go to an adjoining scene.
So for that I was trying to disable gyro.
Thanks,
Darmaniac
What usage case do you have?
Hi! My customer wants panovideo with forced rotation based on some scenario.
For example, when video starts in VR mode, it is necessary to disable gyro (like switching to simple stereo-rendering).
Then we call lookto() and the camera turn on first man. After that we call lookto() and the camera turn on second man. Etc.
Further we enable the gyroscope for full VR mode. There by we allowing user to turn his head after few seconds from start.
I tried use display.stereo and then switch to VR but it is very bad solution because there is no smooth transition.
What is right solution of my task?
How to disable/enable gyro in VR?
Thanks!
They think they want it.. until they experience it once.
Best solution is to fade out and fade in to the desired lookto.
Rotations with the headset on SUCK. PUKE!
Best solution is to fade out and fade in to the desired lookto.
What do yo mean?
Initial task is to fix/hold the camera for the first few seconds of the video, and then activate the gyroscope from this hlookat position. Is it possible in VR mode?
What usage case do you have?
As like others, I need to force the view change to what I'd like to see.
For example, when users look at a hotspot the view looks where the hotspot located and zoom-in (fov change) using like " lookto( 10, 10, 40 ); "
However, there's no use of lookto action in VR mode because Gyro is enabled.
Since that,
I'd like to temporary disable the gyro embeded in WebVR plugin.
Any solution on this?
Kabkee Moon.
Hi,
I'd like to temporary disable the gyro embeded in WebVR plugin.
Any solution on this?
Yes - that's possible - see the 'headtracking' setting in the WebVR plugin documentation here:
https://krpano.com/plugins/webvr/#headtracking
But I wouldn't recommend that - if you want to change the viewing direction in VR, better use the 'lookat' action of the WebVR plugin:
https://krpano.com/plugins/webvr/#lookat
Best regards,
Klaus
Hi Folks,
But I wouldn't recommend that - if you want to change the viewing direction in VR, better use the 'lookat' action of the WebVR plugin:
https://krpano.com/plugins/webvr/#lookat
Has anyone found a smoother solution for the transition between points in the webvr? Unlike lookat, disabling the gyro that could share the xml here?
Thanks!
Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!