Spicing up simple mode using a default.xml
We already discussed that in simple mode, the SPi-V engine builds a simple XML document around the image URL you supply it with. The default XML that is created was explained in this article.
Since SPi-V 1.3 you can replace this default xml document with your own, allowing you to change how panoramas in simple mode are displayed. You can now add your own branding to the simple mode panoramas, set the initial field of view, etc.
<?xml version="1.0" ?>
<tour>
<global>
<meta>
<title>SPi-V panorama</title>
<copyright>2005, Aldo Hoeben | fieldOfView</copyright>
</meta>
<uigroup src="scriptlet-toolbar/toolbar.xml" />
<uigroup src="scriptlet-saver/saver.xml" />
</global>
</tour>This document references the toolbar and saver scriptlets. If you save this file as 'default.xml' and put it in the same folder as your 'SPi-V.dcr' file, the SPi-V engine will automatically load it and base simple mode panoramas on this file.
Internally, SPi-V will insert a new scene element (if none is available), and a panoelement, image and layer to display your simple mode panorama. The XML file will ultimately look like this inside the SPi-V engine:
<?xml version="1.0" ?>
<tour>
<global>
<meta>
<title>SPi-V panorama</title>
<copyright>2005, Aldo Hoeben | fieldOfView</copyright>
</meta>
<uigroup src="scriptlet-toolbar/toolbar.xml" />
<uigroup src="scriptlet-saver/saver.xml" />
</global>
<scene id="simple_scene">
<panoelement id="simple_pano" image="simple_image" />
<image id="simple_image">
<layer class="base" type="bitmap" src="panorama.jpg" />
</image>
</scene>
</tour>
fieldOfView | SPi-V dev