Quick one - delay loadpano

  • I would like to load the pano behind a "first fullscreen intro" image in the startscene but the pano loads very fast and i would like to delay it for a sec.
    Very happy for a advice!

    Best regards - Stefan

  • Don't quite get what exactly you want.

    1) The intro layer covers the whole screen, while pano is loading behind it. When loaded, the intro layer disappears.

    see my tour with such behaviour:

    http://bristol.ua/virtual

    or

    2) The VT is opened and the intro layer is there, and the pano is not loaded behind it. Then, some seconds after, the pano starts loading and the layer disappears. Or user should click the layer for the loading to start.

  • Hi Alexey!

    Thank you for your reply.

    To be honest this is what i am looking for:) - very nicely done indeed with loading
    bar and all, nice panos also!

    My real thought is to load the introscene/ the fullscreen layer before the pano itselv is visible... and then exactly like you fade away the layer and behind that is the VT with the intro information.

    1. Load fullscreen introscene.
    2. when loaded, start load the VT
    3. When VT is loaded fade out the fullscreen image and there is the VT ready with introimage.

    I am trying to figure out how to do this... how are yours done? are you using intro image twice?

    Best regards - Stefan

  • No, I don't use images twice. The idea is: a container layer with preload="true" (see here http://www.krpano.com/docu/xml/#layer.preload) and with all logos inside it has alpha="1" and zorder="10" (so that is is above all other elements) right from the start. On the start of the tour a variable "intro" is set to "yes". Then there's an event which checks "onloadcomplete" and if "intro == yes" triggers a delayedcall with 2-second delay which tweens the intro layer "alpha=0" and enabled="false". Variable "intro" is set to "false" so that "onloadcomplete" event can't trigger the intro anymore.

    The loading bar is done based on the standard "loading_bar" example from Krpano. And again, to used it only during the intro, check the "intro" value, so that the bar appears only during the loading of the first pano.

  • Ah great info Alexey. I will look into this they way you recommend.
    When i look at your VT the first pano shows quick before the layer accours so i will try to find away to delay the first load for half a second, that should be possible.
    Ill keep my progress updated here.

    Great weekend to you!

    Best regards - Stefan

  • Hi,


    I am trying to figure out how to hide a layer until the pano has completely loaded and i'm using this script:


    <layer name="introimage" visible="true" url="Content Boxes/Outside Entrance/Welcome.png" align="center"

    onloaded="set(alpha,0);"

    onloadcomplete="set(alpha,1.0);"

    onclick="hideintroimage();"

    />


    Nothing is coming up however and I have tried many ways of doing this but nothing seems to be working. Anyone who has a quick fix for this i'd love to hear your reply.


    Many thanks! *smile*

  • <layer name="spot1object" visible="false" url="Content Boxes/Outside Entrance/Welcome.png" align="center" alpha="0" autoalpha="true"

    onloaded="set(alpha,0);"

    onloadcomplete="set(alpha,1.0);"

    onclick="closespot1object();"

    />


    <scene name="scene_01_OutsideEntNEW" title="" onstart="tween(layer[spot1object].alpha,1)" thumburl="panos/01_OutsideEntNEW.tiles/thumb.jpg" lat="" lng="" heading="">


    <view hlookat="180" vlookat="0" fovtype="MFOV" fov="120" maxpixelzoom="2.0" fovmin="70" fovmax="140" limitview="lookat"

    vlookatmax="80" vlookatmin="-30"


    />


    This is what I have for the layer and the scene part. But i'm still having issues with it not slowing the layer....

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!