Hi,
in WebVR only hotspots are visible, so that textfield need to be defined as hotspot.
To keep that hotspot always in the center of the view the setting flying="1.0" can be used (btw - if you want a nice paralax effect you can also use there also smaller values e.g. like flying="0.8").
Then the hotspot should be invisible at the beginning (=> alpha=0.0) and above all other hotspots (=> zorder=99).
That's basically all - here an example:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
|
<hotspot name="infotext"
type="text"
html="Hello I'm a Textfield Hotspot"
flying="1.0"
enabled="false"
zorder="99"
alpha="0.0"
distorted="true"
oversampling="2"
depth="500"
scale="0.5"
... other textfield settings for styling ...
/>
|
To make it visible when add onover/onout to the 'other' hotspot that should trigger it and
tween (=animate) there the alpha value to it visible and invisible again:
|
Quellcode
|
1
2
3
4
5
|
<hotspot ...
onover="tween(hotspot[infotext].alpha, 1.0);"
onout="tween(hotspot[infotext].alpha, 0.0);"
...
/>
|
The WebVR cursor works like the mouse and triggers the same events.
Best regards,
Klaus