You are not logged in.

1

Monday, October 8th 2018, 12:54pm

hotspot can't display css icon,layer can,how to solution?

1.link css

Source code

1
<link rel="stylesheet" type="text/css" href="//cdn.materialdesignicons.com/2.8.94/css/materialdesignicons.min.css">


2.xml code-hotspot(can't display css icon)

Source code

1
<hotspot name="spot1" style="test" ath="0" atv="0" html="1235555 [span class='mdi mdi-map-marker-radius' /]" />

Source code

1
<style name="test" type="text" url="%SWFPATH%/plugins/textfield.swf" backgroundcolor="0x000000" backgroundalpha="0.8" css="font-size:20px; color:#ffffff" />


3.xml code-layer(can display css icon)

Source code

1
<layer name="spot1" style="test" ath="0" atv="0" html="1235555 [span class='mdi mdi-map-marker-radius' /]" />

Source code

1
<style name="test" type="text" url="%SWFPATH%/plugins/textfield.swf" backgroundcolor="0x000000" backgroundalpha="0.8" css="font-size:20px; color:#ffffff" />


i want to use hotspot,but it can't display css icon,what's wrong?
arielei has attached the following images:
  • sshot-17.png
  • sshot-18.png

2

Monday, October 8th 2018, 8:34pm

Hi,

add renderer="css3d" to the <hotspot> element.

By default hotspots are rendered by WebGL and there the textfields are created by own custom drawing and not by the browser. Therefore the HTML/CSS support is limited there, re-implementing a 'full-browser' just to get some text would be too much of course.

Btw - note - there is a reason why WebGL is used by default: the performance is better, the cross-browser-compatibility is better, and rendering quality can be better (e.g. when using oversampling and mipmapping), the rendering between the pano and the hotspot is fully sync (CSS3D is slightly async on iOS sometimes), stereo-rendering/vr-support is possible.

Best regards,
Klaus

3

Tuesday, October 9th 2018, 6:31am

many thanks,

add "renderer="css3d" can't display in vr mode.

i found,use iconfont could solve this problem with default value(webgl),like

Source code

1
<hotspot name="spot1" style="test" ath="0" atv="0" html="1235555 [i class='icon iconfont' ]&#xe77d;[/i]" />


it can display in vr mode.

4

Friday, March 15th 2019, 8:30am

hey arielei,
which iconfont do you choose for a working solution?
I can“t get it working...