How to improve loading time for a large tour

  • Hello,

    I've got a large tour with around 100 panoramas. I'm using kprotect to control the download of the starting xml file (~40K) and basic interface graphics, but I'm still getting a blank screen for about 30 seconds on some slower connections. I'm using less than 120K of images for the interface graphics so I know that isn't the delay. I'm pretty sure it the starting xml file's use of include statements to pull in the individual xml files for the nodes. That all totals 480K because of all the embedded hotspots throughout (and increasing). Is there a way to load the individual xml files only when needed, not at the start. Any other advice on how to speed initial loading would be appreciated. The tour works great once it loads, but that initial dead space is a killer. I've even created a "welcome" page where the interface graphics are preloaded in the background, but that isn't fixing it.

    I think my problem likes with the use of the include statement. For example:

    <scene name="scene003" onstart="action(startscene);"><include url="003-s.xml" /></scene>


    Additionally, is there a progress indicator that folks might recommend. Not the one for loading a panorama, but a javascript or css one for the html page itself.

    Thanks,

    Loren

  • Hi!

    1) Don't use include statements, if possible. You can reduce the number of HTTP requests to server by removing include statements.
    2) Don't embed graphics and plugins to the SWF file (not recommended for purchased plugins), if possible. This will add additional overhead on server (additional HTTP requests), but will result in smaller SWF size. Faster your swf file is loaded, the faster engine will starts to download panorama tiles.
    3) Use external XML files to store particular panorama code instead of scenes. The benefits are:
    - smaller swf size (if you embed start xml in the swf)
    - engine will parse start xml faster
    - external XML files are loaded on demand while the user navigates through your virtual tour
    4)<scene name="scene003" onstart="action(startscene);"><include url="003-s.xml" /></scene> - this code is bad. Scenes are used to store panorama code directly in XML file. Include statements here is excess. Replace include statements with panorama code or remove all the scene tags from start xml and use external XML files to store panorama code.


    If your start XML file contains around 100 scenes tags with include statement, the engine will preload them first, and then execute the start action in start XML file.

    Edited 2 times, last by jaydee (February 17, 2011 at 5:37 AM).

  • Jaydee,

    Thanks for confirming what I thought the problem was.

    Unfortunately, I've got a lot of code to change. Just to make sure before I start, I see two main changes:

    1) delete the include statements from the starting xml file

    2) I'm using a map and hotspots for navigation between panoramas, so if I am not going to use scene tags, then statements like this:

    onclick="loadscene(scene002, null, MERGE, BLEND(1));"

    needs to change to this:

    onclick="loadpano(002-s.xml, null, MERGE, BLEND(1));"

    Is that correct?

    R,

    Loren

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!