本人所用Unity版本2019_3_1,Vuforia版本9.1.7(目前的最新版本)。
1.用unity新建一个工程
2.按照路径E:/UnityProjrectFile/Test_Vuforia_9_1_7_GroundPlane_2019_3_1/Packages(我的路径是这样的,在工程的根目录可以看到)打开Packages文件夹。
3.在Packages文件夹里面放入 https://dev.azure.com/vuforia-engine/unity-extension/_packaging?_a=feed&feed=unity-packages%40Local 这个链接下载解压后的文件夹(将名称“package”改为“com.ptc.vuforia.engine”),如下图所示:
4.修改上图中的manifest.json文件如下所示:
{
"scopedRegistries": [
{
"name": "Vuforia",
"url": "https://registry.packages.developer.vuforia.com/",
"scopes": [
"com.ptc.vuforia"
]
}
],
"dependencies": {
"com.ptc.vuforia.engine": "9.1.7",
"com.unity.collab-proxy": "1.2.16",
"com.unity.ext.nunit": "1.0.0",
"com.unity.ide.rider": "1.1.4",
"com.unity.ide.vscode": "1.1.4",
"com.unity.package-manager-ui": "2.2.0",
"com.unity.test-framework": "1.1.11",
"com.unity.textmeshpro": "2.0.1",
"com.unity.timeline": "1.2.10",
"com.unity.ugui": "1.0.0",
"com.unity.xr.management": "3.2.9",
"com.unity.modules.ai": "1.0.0",
"com.unity.modules.androidjni": "1.0.0",
"com.unity.modules.animation": "1.0.0",
"com.unity.modules.assetbundle": "1.0.0",
"com.unity.modules.audio": "1.0.0",
"com.unity.modules.cloth": "1.0.0",
"com.unity.modules.director": "1.0.0",
"com.unity.modules.imageconversion": "1.0.0",
"com.unity.modules.imgui": "1.0.0",
"com.unity.modules.jsonserialize": "1.0.0",
"com.unity.modules.particlesystem": "1.0.0",
"com.unity.modules.physics": "1.0.0",
"com.unity.modules.physics2d": "1.0.0",
"com.unity.modules.screencapture": "1.0.0",
"com.unity.modules.terrain": "1.0.0",
"com.unity.modules.terrainphysics": "1.0.0",
"com.unity.modules.tilemap": "1.0.0",
"com.unity.modules.ui": "1.0.0",
"com.unity.modules.uielements": "1.0.0",
"com.unity.modules.umbra": "1.0.0",
"com.unity.modules.unityanalytics": "1.0.0",
"com.unity.modules.unitywebrequest": "1.0.0",
"com.unity.modules.unitywebrequestassetbundle": "1.0.0",
"com.unity.modules.unitywebrequestaudio": "1.0.0",
"com.unity.modules.unitywebrequesttexture": "1.0.0",
"com.unity.modules.unitywebrequestwww": "1.0.0",
"com.unity.modules.vehicles": "1.0.0",
"com.unity.modules.video": "1.0.0",
"com.unity.modules.vr": "1.0.0",
"com.unity.modules.wind": "1.0.0",
"com.unity.modules.xr": "1.0.0"
}
}
5.然后再回到Unity里面,打开AssetStore,搜索VuforiaEngine,导入。
6.在下图填写Vuforia官网申请的Key,就可以开始使用了。
如果需要附带Vuforia9.1.7的Unity工程,可以下载这篇文章https://blog.csdn.net/weixin_43779625/article/details/100703976底部的工程。