If I try to convert a functioning tour into a standalone Exe with kprotect, i get a fatal error as big line in the middle of the screen, after starting the generated Exe, in my case saying:
"FATAL: scene1/scene1.xml - loading error (IO Error)".
The crazy thing is that the tour is OK, the loading has happened - only the error message stays permanently.
I have a complicated folder structure - separating common parts and tour dependant parts, with the panoramas of a tour in separate subfolders sceneX. But my problem can be stripped down to the following files:
<swfdir>/proj/Test1/test.xml (the Startup XML)
<swfdir>/proj/Test1/scene1/scene1.xml
<swfdir>/skin/common.xml
<swfdir>/proj/Test1/test.html (the Startup HTML)
I'm working under Windows Vista with the latest beta (krpano.swf 1.0.8.14, build 2011-05-20) and "krpano Protect Tool.exe" from 2011-04-11. The Placeholder paths are set, with BASEDIR to "<swfdir>/proj/Test1"
The files:
<swfdir>/proj/Test1/test.xml:
<krpano version="1.0.8" onstart="new_pano(scene1);">
<include url="%SWFPATH%/skin/common.xml" />
</krpano>
<swfdir>/proj/Test1/scene1/scene1.xml:
<krpano version="1.0.8" onstart="showlog(true);trace('scene1 working');" >
<preview type="grid(cube,16,16,512);" />
</krpano>
<swfdir>/skin/common.xml:
<krpano version="1.0.8" >
<action name="new_pano">
<!-- loadpano(%HTMLPATH%/%1/%1.xml); -->
loadpano(%_BASEDIR%/%1/%1.xml);
</action>
</krpano>
(I couldn't enter BASEDIR correct in the forum editor)
<swfdir>/proj/Test1/test.html:
<html>
<head>
<title>KRPano Protect Problem</title>
<style> html { height:100%; } body { height:100%; } </style>
</head>
<body>
<div id="krpanoDIV" style="width:100%;height:100%;"> </div>
<script src="../../swfkrpano.js"></script>
<script>
var viewer = createPanoViewer({swf:"../../krpano.swf", id:"krpanoSWFObject", target:"krpanoDIV"});
viewer.addVariable("xml", "Test.xml");
viewer.embed();
</script>
</body>
</html>
Display More
If kprotect loads and resolves Test.xml, it shows an error in red: "../Test1/%1%1.xml" not found.
I had to add "scene1/scene1.xml" to the embedded Xml files manually, because it is loaded dynamically.
Another distyturbing thing is: if i substitute BASEDIR in common.xml with HTMLPATH, the loading doesn't happen - only the error message is shown.