位置: 编程技术 - 正文

Vuforia How To Use Android Plugins in Unity Apps

编辑:rootadmin
How To Use Android Plugins in Unity Apps

推荐整理分享Vuforia How To Use Android Plugins in Unity Apps,希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:,内容如对您有帮助,希望把文章链接给更多的朋友!

Vuforia How To Use Android Plugins in Unity Apps

This article explains how to do two things:

Take custom Android plugins that are written in Java and integrate them into a Vuforia-based Unity projectInvoke methods defined in the Java plugin from a Unity C# script.The Image Targets sample is a starting point for a Unity project example.Integrate plugins into a Vuforia-based Unity projectCreate a Unity project. For ease of reference we refer to it as QcarWithPlugin.Import the Image Targets sample package for Unity(Menu > Assets > Import custom package)Double-click the Image-Targets scene in the project view. The three Image Targets and their associated teapot models should appear in the scene view.Create a new Android project in Eclipse. For ease of reference the project is called MyPlugin, so it is assumed that the main activity will be called MyPluginActivity.Right-click on the project in Eclipse, go to Properties > Java Build Path > Libraries. Add the following two libraries as external jars (both located under the Assets/Plugins/Android/ folder of the Unity project):QCAR.jarQCARUnityPlayer.jarOpen the MyPluginActivity.java file in Eclipse, and make the following code changes:Make MyPluginActivity extend QCARPlayerActivity instead of Activity. Press Ctrl-Shift-O to adjust the imports automatically.From the onCreate() method, remove the line setContentView(…).Add a custom public method called showMessage() to the MyPluginActivity class. Fill the method with some code to display a Toast message with text.The code of your MyPluginActivity should look like the following code:Invoke methods defined in the Java pluginRight-click on your project, go to Properties > Android, and check the IsLibrary checkbox to turn your Android project into a library.This action should make Eclipse generate a .JAR file (for example, myplugin.jar) and store the file in the /bin folder of your Eclipse project.Open the /bin folder and copy the JAR library from that folder to the Assets/Plugins/Android/ folder of your Unity project.Open and edit the AndroidManifest.xml file located in the same Assets/Plugins/Android/ directory.Replace the name of the main activity with your fully qualified Activity name, for example, com.my.org.MyPluginActivity.Create a C# script, call it MyPluginCaller, for example, and attach it to each of your Image Targets in the scene (Chips, Stones, Tarmac, etc.).Copy and then paste the following code in your script. The code will make your script invoke the showMessage() method of your MyPluginActivity class whenever a target is detected:Now the project should be ready to build and run on your Android device.原文地址点击这里

unity3d移动平台减小安装包大小专题(5):共用动作文件 以前就觉得很多武将的动作其实差不多,例如受击,死亡,但鉴于武器不同,就没处理,而且只是共用一两个动作带来的性价比不高。但最近来的小兵

Unity3D定时器的调用 转载自:

【北漂勇士】利用unity和NGUI开发一个RPG类型的游戏 我计划从明天开始,额,是从今天开,始,大概用一学期的时间开发一款角色扮演类型的游戏,作为我将来找工作时展示的作品吧,我特意找到了《dunge

标签: Vuforia How To Use Android Plugins in Unity Apps

本文链接地址:https://www.jiuchutong.com/biancheng/382564.html 转载请保留说明!

上一篇:Unity3D中的Prefab使用方法(unity preferences)

下一篇:unity3d移动平台减小安装包大小专题(5):共用动作文件(unity3d移动代码)

  • 个人生产经营所得税怎么计算
  • 更正个税申报需要做账吗
  • 未认证的发票如何作废
  • 个税和社保基数不一致会影响上海落户吗
  • 金蝶打印凭证页码范围
  • 外购商品赠送客户怎么做账
  • 不够起征点免缴的增值税如何做税务处理?
  • 增值税普通发票和专用发票有什么区别
  • 个人所得税0申报逾期
  • 税务局即征即退自查报告
  • 小型微利企业所得税优惠政策
  • 一般户可以收货款么
  • 其他综合收益影响净利润吗
  • 增值税主要有三种类型
  • 生产企业是否可以兼营外贸业务
  • 公益性生物资产有哪些
  • 怎么把过期银行卡的钱取出来
  • 个税系统添加单位企业信息不存在
  • 稽查补缴增值税怎样做账
  • 长期资产的含义
  • saproxy.exe - saproxy是什么进程 有什么用
  • 预收款项的减少
  • psoft1.exe - psoft1是什么进程 有什么作用
  • vscode国内镜像
  • 现行小规模纳税人增值税税率
  • 借支单还款后借支单要还么
  • php的递归
  • php新手入门
  • 应收票据贴现的性质是什么
  • 海关交税标准表
  • 结转损益类收入科目
  • 个体户生产经营所得减免政策
  • 报表重分类和不重分类
  • css教程网站
  • python怎么将整数转化为字符串
  • 下岗职工生活费停发
  • 收到招标文件怎么回函
  • 退还多缴纳税款
  • 应付账款和预付账款的会计分录
  • 发生售后维修领用材料分录
  • 印花税的税率变动
  • 支付债券发行费怎么算
  • sql2008使用教程
  • 一整天的时间从几点到几点
  • sql server使用sql server身份登录
  • 所得税 补税
  • 固定资产减值准备借贷方向
  • 拆迁补偿款收税吗
  • 将自产产品用于管理部门 增值税
  • 建筑工程社会实践报告
  • 甲方代付农民工工资谁报个税
  • 技术服务所发生的事故
  • 社保税款所属期申报错了要紧吗?
  • 发票勾选认证成功了是不是就可以抵扣呀
  • 收到支票如何去银行兑现
  • 建账需要准备什么东西
  • centos6.2安装
  • mysql安装配置教程5.7.25
  • 最基本的长度单位是什么
  • windows自带截图保存在哪里
  • fix it club
  • FreeBSD su Sorry问题解决办法
  • window系统大全
  • macbookpro怎么删除快捷方式
  • centos安装rz命令
  • win8中的wps点打印预览就卡
  • win10系统升级后共享打印机不能用
  • WIN10任务栏时间不动
  • pg环境变量
  • node.js基础入门
  • js单线程多线程
  • sell脚本
  • javascript性能优化写法
  • 在python中通过什么语句创建一个空集合
  • 税务文书送达回证模板
  • 季度预缴申报表在哪里查询
  • 车辆过户给自己家人
  • 重庆纳税申报流程
  • 增值税专用发票怎么开
  • 税控发票打印发票流程
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

    网站地图: 企业信息 工商信息 财税知识 网络常识 编程技术

    友情链接: 武汉网站建设