位置: 编程技术 - 正文

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

  • 计提递延所得税资产
  • 个人向公司提供劳务,开发票
  • 代扣代缴增值税是什么意思
  • 补缴的税款和罚款的会计处理
  • 取得研发样品收入
  • 作废的发票验旧之后怎么领取新发票
  • 福利费专票进项可以抵扣吗
  • 税务逾期记录怎么消除不了
  • 母子公司无偿划转资产涉税
  • 超范围经营是不是就等于无证经营
  • 建筑施工企业的法定代表人对本企业的安全生产负责
  • 自产自用应税消费品
  • 股东分红利息
  • 融资租赁咨询服务合同需要交印花税吗
  • 固定资产报废的账务处理例题
  • 收到公众号申请的小额打款认证怎么入账?
  • 开公司财务流程
  • 超30日未备案
  • 企业所得税中的不征税收入有哪些
  • 股权转让个人交的印花税可以入账吗
  • 建筑行业劳务费会计分录
  • 增值税扣款凭证包括
  • 宽带合同属于什么合同
  • 员工意外伤害保险怎么买
  • macos usb启动
  • 合同印花税的5个税目
  • 旅行社代订的住宿费可以抵扣吗
  • 公司收到的应收股利需要分配利润吗
  • php中session的作用
  • 应收账款转让的风险
  • 出库单可以补吗
  • php的数组函数
  • 试用期人员工资财务记账
  • 小规模年底税金怎么做账
  • zend framework手册
  • ps_clk
  • php 后端
  • Python中如何定义一个变量
  • mongodb常用命令
  • mongodb快速入门
  • 购买工业用地
  • 门诊收费票据能重新打印吗
  • 保证人不承担责任的情形(上)
  • 处置可供出售金融资产原先进入公允价值变动损益
  • sqlserver2008r2评估期已过
  • Ubuntu上安装jdk
  • 国家税务总局公告2011年第25号公告
  • 上年度企业所得税调整需要调账吗
  • 房地产开发公司注册资金要求
  • 长期待摊费用每个月摊销多少
  • 每月需要计提的分录
  • 跨年冲红发票账务处理需要调整申报表吗
  • sql中分页
  • windows mobile应用下载
  • win10 电池报告
  • win2003r2企业版密钥
  • linux 显示
  • redhat图形化界面启动
  • fedora怎么用
  • 在一台电脑安装两个省份个税系统
  • 苹果mac双系统好不好
  • centos查看某个端口
  • macos使用方法
  • win7系统莫名其妙占用个D盘
  • 收不到windows的验证码
  • xp系统不能正常启动怎么修复
  • win7不能运行应用程序的方法
  • win8.1快速启动
  • fedora update-grub
  • 方块滚动代码怎么写
  • 简单谈谈对中国电信的认识
  • windows升级node版本
  • 编写批处理
  • data命令
  • unity2d ui
  • 关于numpy中loadtxt函数的说法
  • jquery用法
  • 小规模纳税人可以开13%的发票吗
  • 贸易公司服装
  • 企业所得税年报什么时候结束
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设