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.
The pre-releases are using CSS3D by default for normal rendering and WebGL when stereo-rendering.Does the 1.19 use WebGL-Hotspots or still CSS3D?
![]() |
Source code |
1 2 3 4 |
<!-- TEMP PRE-RELEASE STUFF --> <display hotspotrenderer="webgl" devices="html5" /> <!-- force using WebGL for the hotspots --> <view continuousupdates="true" devices="html5" /> <!-- constantly update the screen (required for WebGL hotspots for the moment) --> <!-- TEMP PRE-RELEASE STUFF --> |
But with the final 1.19 release the hotspots will be rendered by WebGL by default.
This post has been edited 1 times, last edit by "James Hay" (Sep 29th 2015, 10:39pm)
![]() |
Source code |
1 2 3 |
for(set(i,0), i LT hotspot.count, inc(i), if(hotspot[get(i)].linkedscene,if(hotspot[get(i)].style EQ 'skin_tooltips', set(hotspot[get(i)].style,'skin_hotspotstyle'););); ); |
Klauss, just replaced the vtourskin.xml and the webvr files with the files from 1.19-pr3 and it is now not displaying stereoscopic at all. I'm confused as to what I'm doing wrong here. Thanks for your help.Try using the vtourskin.xml from 1.19 pre-release 3.
Location: Netherlands
Occupation: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer
Hmm... with which version do you compare?but question is why loadstyle is overwriting style attribute.
Your colorrun.xml is wrong - you are including there the webvr.xml (and an additionally gyro - why?) and this changes/overwrites the WebVR settings that were made in the vtourskin.xml.Klauss, just replaced the vtourskin.xml and the webvr files with the files from 1.19-pr3 and it is now not displaying stereoscopic at all. I'm confused as to what I'm doing wrong here. Thanks for your help.
Exactly. I want to replace the image of the hotspot with an dynamic texture, which I can control with javascript.
![]() |
Source code |
1 2 3 4 5 6 7 |
if (krpano.webGL) { // have WebGL support // get the WebGL context var gl = krpano.webGL.context; } |
![]() |
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
/ get the hotspot var hotspot = krpano.get("hotspot[NAME]"); // get the hotspot WebGL texture (only possible when the texture was at least once rendered via WebGL) if (hotspot.GL) { var texture = hotspot.GL.tex; if (texture) { // do some stuff with the texture - e.g. bind it to a custom framebuffer: gl.bindTexture(gl.TEXTURE_2D, texture); gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, your_tex_width, your_tex_height, 0, gl.RGBA, gl.UNSIGNED_BYTE, null); gl.bindFramebuffer(gl.FRAMEBUFFER, your_framebuffer); gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0); gl.bindFramebuffer(gl.FRAMEBUFFER, null); gl.bindTexture(gl.TEXTURE_2D, null); } } |
Klauss,
Your colorrun.xml is wrong - you are including there the webvr.xml (and an additionally gyro - why?) and this changes/overwrites the WebVR settings that were made in the vtourskin.xml.Klauss, just replaced the vtourskin.xml and the webvr files with the files from 1.19-pr3 and it is now not displaying stereoscopic at all. I'm confused as to what I'm doing wrong here. Thanks for your help.
Please don't try adding xml code in an 'experimental way', as you can see this leads to non or wrong working stuff. Either remove the webvr.xml and the gyro from the xml or use the default output xml code.
Best regards,
Klaus
This post has been edited 1 times, last edit by "James Hay" (Sep 29th 2015, 10:38pm)
![]() |
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
<krpano onstart="loadscene(demo)"> <scene name="demo"> <preview type="grid(CUBE,16,16,512,0xCCCCCC,0xFFFFFF,0x999999);" /> <!-- Not showing on flash --> <style name="popup_hotspot_style" url="%SWFPATH%/skin/images/info.png" keep="true" /> <hotspot style="popup_hotspot_style" ath="-30" atv="0" /> <!-- Showing on flash --> <hotspot url="%SWFPATH%/skin/images/info.png" ath="30" atv="0" /> <!-- showing on flash but alpha is not applied --> <style name="popup_hotspot_style1" alpha="0.5" keep="true" /> <hotspot style="popup_hotspot_style1" ath="-60" atv="0" url="%SWFPATH%/skin/images/info.png" /> <!-- Works on flash --> <hotspot onloaded="loadstyle(popup_hotspot_style1)" ath="-90" atv="0" url="%SWFPATH%/skin/images/info.png" /> </scene> </krpano> |
This post has been edited 1 times, last edit by "Zephyr" (Sep 10th 2015, 9:50pm)