我正在为我的增强现实移动应用(iOS)项目使用wikitude插件和phonegap。我的问题是,即使我的相对路径是正确的,我也无法加载建筑师世界。它在我的屏幕上没有显示任何内容。
截图
我在index.js中的代码
loadARchitectWorld: function(sample) {
if (app.isDeviceSupported) {
WikitudePlugin.loadARchitectWorld("www/world/5_BrowsingPois_3_LimitingRange/index.html");
// if you want to listen to document.location = architectsdk://yourhost?param1=foo¶m2=bar simply set the onUrlInvoceCallback
WikitudePlugin.setOnUrlInvokeCallback( app.onClickInARchitectWorld );
}
},
我的文件夹结构。
答案 0 :(得分:0)
您是否看过Wikitude PhoneGap sample application?它使用相对路径加载世界。
您还可以为isDeviceSupported
和loadARchitectWorld
设置onError回调(WikitudePlugin上有变量,您可以在其中为世界加载错误设置自定义回调函数)。