位置: 编程技术 - 正文

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移动代码)

  • 企业注册资金需要拿钱出来吗
  • 哪些税不用通过应交税费
  • 所有者权益分配流程
  • 增值税少企业所得税多说明什么
  • 个人所得税年度汇算时间
  • 公司能经营烟草公司吗
  • 股权转让分期付款合同范本
  • 农产品是零税率还是免税税率
  • 抄税报税清卡怎么操作流程
  • 金税盘的发票怎么作废
  • 个独企业缴纳个人经营所得税额的会计分录
  • 购买电脑的折旧怎么计算
  • 现金流量怎么影响股票价值
  • 预收和应收可以冲销吗
  • 金税盘坏了更换需要几天
  • 资产负债表项目的编制方法
  • 一般纳税人销售旧货
  • 非营利性科研机构接受企业基础研究收入免征企业所得税
  • 增值税普通发票可以抵扣吗
  • 购买非专利技术发生的手续费计入什么科目
  • 收到托收凭证怎么填写
  • 网上平台服务年费应该计入什么费用?
  • 商贸公司结转成本应该贴什么凭证
  • 第三方协议补贴
  • 收到外币货款的汇率
  • 房屋维修专用发票图片
  • 一个人有多份工作
  • 应交税费不核算
  • 药企常见税务风险及措施
  • 货代企业所得税优惠政策
  • 资产负债表应收账款是负数怎么回事
  • 拆迁安置房如何写两人名字
  • 固定资产属于金融负债吗
  • mac safari使用技巧
  • explorer.exe是啥意思
  • win7怎么删除windows.old
  • 阿佩勒斯
  • 年底所得税账务处理
  • oss对象储存的副本储存原则
  • 卢塞恩小镇瑞士
  • 购车的进项税怎么抵扣
  • 网站top排行榜
  • 预交增值税款在申报表哪里填列的
  • micro start
  • phpcms添加内容
  • web开发百度百科
  • mysql分表的3种方法
  • mysqli删除
  • 水运企业会计核算办法
  • 实收资本变化
  • 电脑买回来可以直接用吗
  • 融资租赁手续费进项税能抵扣吗
  • 旅行社差额征税全额开票和差额开票
  • 红字申请单如何打印出来
  • 如何计算债券实际收益
  • 销售折让如何核算
  • 2020年专项扣除怎么填
  • 买一送一会计分录怎么写
  • 会计凭证负数金额怎么算
  • 无形资产的研发支出
  • 设计会计凭证
  • mysql的函数
  • ubuntu /opt
  • lsass.exe
  • kcleaner.exe是什么
  • Mac系统修复怎么进入
  • 如何教新手
  • 主流安卓开发
  • shell脚本实现文件移动、复制等操作
  • webuploader使用教程
  • Linux中获取某个进程的系统调用以及参数(故障排查案例)
  • Node.js中的事件循环是什么样的
  • 单机模式在哪
  • python向oracle写入
  • android加载gif图片
  • 车辆购置税怎样交
  • 国家税务总局通知公告
  • 税务申报系统如何改成密码登录
  • 三证合一 税务
  • 职业年金利息计入哪个科目里面
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设