You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

mham

Beginner

  • "mham" started this thread

Posts: 28

Location: Stockholm, Sweden

  • Send private message

1

Wednesday, April 22nd 2020, 10:49pm

gyro2 plugin usage

Hi

I have a very basic beginners' question.
I have never used any plugins.
Now I am trying to get the gyro2 plugin work with my existing panoramas, but cannot make it work.
I get the error "No gyroscope available..." message.

I guess that it means that krpano cannot find the gyro2.js, right?
But I have the gyro2.js in the same location as the panorama .xml file.
in the xml file I have url="gyro2.js" in the <plugin> tag, but it does not work anyway (see my xml in the following!)

Any ideas?

Thanks,
/MH


<krpano version="1.19-pr16">
<include url="general2.xml"/>
<include url="skin/defaultskin.xml"/>
<plugin name="gyro" devices="html5" url="gyro2.js" enabled="false" onavailable="gyro_available_info();" onunavailable="gyro_not_available_info();" softstart="1"/>
<action name="gyro_available_info">
set(layer[infotext].html, 'Gyroscope available, press the gyro button...'); set(layer[gyrobutton].visible, true);
</action>
<action name="gyro_not_available_info" xautorun.flash="onstart">
set(layer[infotext].html, 'No gyroscope available...');
</action>
<view limitfov="true" fovmax="125" fovmin="45" maxpixelzoom="1.0" architectural="0.4" fov="70" hlookat="0" vlookat="0"/>
<preview url="../flashmedia/galerie_apollon.tiles/preview.jpg"/>
<image>
<cube url="../flashmedia/galerie_apollon.tiles/pano_%s.jpg"/>
<mobile>
<cube url="../flashmedia/galerie_apollon.tiles/mobile_%s.jpg"/>
</mobile>
</image>
<layer name="bottombar" type="container" bgcolor="0x000000" bgalpha="0.5" align="leftbottom" width="100%" height="40">
<layer name="infotext" type="text" background="false" border="false" enabled="false" html="" css="text-align:left; color:#FFFFFF; font-family:Arial; font-size:14px; font-weight:bold;" align="left" x="10" height="100%" vcenter="true"/>
<layer name="gyrobutton" url="gyroicon.png" scale="0.5" align="right" x="10" visible="false" onclick="switch(plugin[gyro].enabled);"/>
</layer>
</krpano>

Tuur

Sage

Posts: 3,337

Location: Netherlands

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

  • Send private message

2

Thursday, April 23rd 2020, 10:13am

Try:

Add keep="true" to the gyro plugin code
And
Perhaps also the path is wrong..
plugins/gyro2.js
??

On which device you test?
Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

mham

Beginner

  • "mham" started this thread

Posts: 28

Location: Stockholm, Sweden

  • Send private message

3

Thursday, April 23rd 2020, 5:56pm

Hi,

Added keep="true" to the gyro plugin to no avail.
As I had mentioned I had gyro2.js in the same directory as the xml file, that's why the path should not been wrong, but anyways, I created a directory called "plugins" and moved the gyro2.js to there, also changed the path to "url=plugins/gyro2.js", just to test it but it did not help either :(

I am using this on a Samsung Galaxy S10, is there any known issues with that specific phone?

Otherwise I am puzzled why this does not work.
Feel free to check this out with any panorama on my site using a mobile phone.

Regards,
/MH
www.stockholm360.net

Similar threads