Sie sind nicht angemeldet.

Red

Schüler

  • »Red« ist der Autor dieses Themas

Beiträge: 99

Wohnort: Australia

Beruf: Virtual tour creator, VR app developer

  • Nachricht senden

1

Mittwoch, 28. Oktober 2015, 08:30

Some layers still showing in VR Mode

Hi,

When in VR mode there are still some layers appearing. I was under the impression that no layers would show when in VR mode, which is what I require.

For example, a background layer still shows. The layer is set to automatically appear onstart for each scene. Any layers with the textfield plugin under this layer don't show in VR.

Quellcode

1
2
<layer name="scenetextlayer" zorder="6" type="container" devices="mobile" altonloaded="" keep="true" align="center" x="0" y="0" width="90%" height="60%" visible="true" alpha="0" bgcolor="0x08103d" bgalpha="0.7" enabled="true">
.........</layer>



Any ideas why this is the case? Is is because the layer type is a container? I've set visibility as false or true in the onentervr/onexitvr events, which works okay to hide/show the layer.
But when switching to another scene while in VR mode the layer shows up again.

Just wondering if there's any way to make sure ALL layers are hidden when in VR mode.

Thanks for any help

2

Mittwoch, 28. Oktober 2015, 08:53

Hi,

the hiding of the layers is a 'xml feature', not a plugin one.

See the webvr.xml for details - there in the 'webvr_onentervr' action all layers without vr="true" will be hidden.

But when dynamically adding new layers at runtime they will appear of course (just as note - not in real WebVR in Chromium, there only WebGL content will be visible).

You could check for 'webvr.isenabled' before adding new layers or to set their visibility accordingly or even implement some custom solution by modifying the webvr.xml or by using the WebVR plugin directly without webvr.xml.

Best regards,
Klaus

Red

Schüler

  • »Red« ist der Autor dieses Themas

Beiträge: 99

Wohnort: Australia

Beruf: Virtual tour creator, VR app developer

  • Nachricht senden

3

Mittwoch, 28. Oktober 2015, 09:10

Thanks for the info and clarification Klaus

4

Donnerstag, 22. September 2016, 22:56

Yikes, just when I think I'm done... I've got this same issue: my map is showing up in webvr.

I don't understand the instructions:

there in the 'webvr_onentervr' action all layers without vr="true" will be hidden.



Since my map layer is loaded from the tour.xml, how in the world can I hide it when entering webvr?

Tnx

5

Freitag, 23. September 2016, 10:26

Hi,

when adding or showing elements dynamically check the webvr.isenabled setting if the VR mode is currently enabled.

Best regards,
Klaus

6

Freitag, 23. September 2016, 15:12

Sorry Klaus, but I'm at the limits of my understanding about how this works. *sad*

Where exactly am I placing the if="!webvr.isenabled" ?


I've tried locating in the map layer within tour.xml:

<layer name="map" url="graphics/inmap.png" if="!webvr.isenabled"



But that has no effect - the map still shows up in webVR.

Is there another location that it needs to go? Do I have to edit the webvr.xml?

7

Freitag, 23. September 2016, 17:16

started a new thread to clarify the problem here .

Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von »landrvr1« (23. September 2016, 21:34)