Unity3d四 android 添加unity3d view

来源:互联网 发布:手机天猫 手机淘宝 编辑:程序博客网 时间:2024/05/01 01:37
android 添加unity3d view
在Android中嵌入Unity3d
https://forum.unity3d.com/threads/using-unity-android-in-a-sub-view.98315/ //Using Unity Android In a Sub View 
http://www.41post.com/5292/programming/unity-and-android-create-an-unity-app-with-a-custom-layout //example
http://www.jianshu.com/p/a7d82b3ac0c4 //将unity3d工程打包,导入到android工程
下面http://www.ithtw.com/2910.html这种方式不好
http://stephen830.iteye.com/blog/2088504 //将android工程打包成jar包,导入到unity3d工程
1.上面导出的jar文件(Test.jar)如果用解压软件打开会发现,除了class文件,还有项目中的资源文件、lib库,这样虽然这个jar文件在unity中可以使用,
但增大了文件大小,因此可以用下面的方法来导出一个纯净的jar文件(只含有class文件)。
代码所有的.class文件都生成在了Android工程的bin文件夹中,当前工程的路径是 TestUA->bin->classes->com->ITFFuture->testua->你的.class文件。
下面需 要对这些.class文件进行打包,苹果系统的话打开电脑的终端,cd到classes文件夹的目录下,接着执行代码
2.在 unity中,我们新建一个Plugins文件夹,Plugins下面又建Android文件夹,Android文件夹下再建一个bin文件夹,我们将我 们导出的jar包放进这个文件夹下,
然后我们在eclipse中的res文件复制一份放入Android。也要把AndroidManifest.xml 放进Android目录下。
http://www.ceeger.com/Manual/PluginsForAndroid.html
http://www.jb51.net/article/51938.htm //如何在Unity中调用Android中的WebView组件,实现内部浏览器样式的页面切换
http://johncookie.iteye.com/blog/1997636 //Unity3D中 Android插件findviewbyid返回null的解决办法
http://blog.csdn.net/yueqian_scut/article/details/44590383 //能不能将Unity作为Android界面的一部分嵌入到Android应用中
https://stackoverflow.com/questions/21236094/integrate-unity3d-view-into-android-activity //add actionbar and menus
http://www.cnblogs.com/kenzi/p/3424746.html
Unity Asset Store和Unity Wiki
http://www.unitymanual.com/thread-37106-1-1.html
http://www.wang1314.com/doc/topic-504236-1.html
https://docs.unity3d.com/Manual/android-GettingStarted.html
http://blog.csdn.net/yangxuan0261/article/details/52427119
https://docs.unity3d.com/Manual/PluginsForAndroid.html