unity3d

Kotlin and Unity development error

前提是你 提交于 2020-12-31 05:49:33
问题 I use Android Studio and Unity development, the Library packaged into aar file, and then the aar file as a Unity plug-in. When I use Java, no problem, but when using Kotlin, it will throw an exception. Thanks! Exception: AndroidJavaException: java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; at com.lsl.plugin.PluginActivity.showToast(PluginActivity.kt) at com.unity3d

Kotlin and Unity development error

五迷三道 提交于 2020-12-31 05:48:36
问题 I use Android Studio and Unity development, the Library packaged into aar file, and then the aar file as a Unity plug-in. When I use Java, no problem, but when using Kotlin, it will throw an exception. Thanks! Exception: AndroidJavaException: java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; at com.lsl.plugin.PluginActivity.showToast(PluginActivity.kt) at com.unity3d

Kotlin and Unity development error

心已入冬 提交于 2020-12-31 05:47:07
问题 I use Android Studio and Unity development, the Library packaged into aar file, and then the aar file as a Unity plug-in. When I use Java, no problem, but when using Kotlin, it will throw an exception. Thanks! Exception: AndroidJavaException: java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/jvm/internal/Intrinsics; at com.lsl.plugin.PluginActivity.showToast(PluginActivity.kt) at com.unity3d

3D展示框架SDK功能介绍,支持二次开发

早过忘川 提交于 2020-12-30 17:55:46
什么是SDK? SDK就是软件开发工具包(SDK全称:Software Development Kit)是应用软件时的开发工具集合。 老子云3D展示框架SDK 技术内容介绍: 1、模型的3D展示和编辑: 产品模型可720°旋转、放大缩小、显示尺寸、播放动画、细节部位拆分; 2、场景展示与应用: 浏览场景各处,可对移动速度、视角高度进行调整向场景内添加模型,调节场景光线强度,可随意拖动模型,并对模型进行单独编辑(复制、替换、翻转、复位等); 3、用户参与设计与互动: 可进行多人同屏,把模型拖入AR场景,并能对模型、场景的操作(包括人物移动、旋转、对模型的所有操作等); 4、个性需求定制化: 可对产品展示及功能进行个性定制,已达到产品的最佳展示状态。 老子云SDK技术核心优势:A 功能自定义打包下载; 支持模型多格式(AMRT/OBJ/FBX); 多平台化的兼容适配(安卓、IOS、web、PC端); 适用范围广,节省开发时间和成本; 海量的3D模型免费资源; 3D展示框架SDK适用于基于3D应用的开发公司、个人开发者 。在模型应用层面真正做到全平台互通,轻松实现模型应用在多平台、跨端展示、交互。 案例: 北京某产业园区要打造智慧园区,如果按照以前的开发模式,需要业务开发人员5人,3D建模师3人,Unity开发4人,团队总共需要12人,整个开发周期预计6个月以上。使用老子云SDK开发后

Visual Studio 2019 ignoring tab preference

自闭症网瘾萝莉.ら 提交于 2020-12-30 08:50:30
问题 I was programming in VS2019 this morning before going about my day. When I sat down in the evening to keep programming, I realized that it has suddenly been placing spaces instead of tabs! My preferences are set for every language to place tabs instead of spaces, and has been doing so in previous days. I updated VS to make sure, but the problem persists - regardless of my preference settings, out of nowhere spaces are being placed instead of tabs. PS: I am aware that this question has already

Can't add modules to installed Unity editors

我与影子孤独终老i 提交于 2020-12-30 07:56:59
问题 I'm trying to add the Android SDK Module to an Editor that I have installed on my PC. I've looked it up online and the guide available here states that there should be an "Add Modules" option available from the menu but it is absent from the menu when I open it in my Unity Hub: 回答1: I got strait solution for this issue No reinstall require. No redownload require. One click Restore all unity editors including Modules. Remove Unity editor from the hub. Go to Unity hub setting. From General tab

图形学 遮挡剔除算法综述

血红的双手。 提交于 2020-12-29 17:49:58
1. Hidden Line Removal (HLR) 在光栅化的文章中,我们使用Z-Buffer来判断三角形面片是否遮挡,但Z-Buffer不适用于纯线框的模型的遮挡剔除。原因如下。 就如同上图左侧,在A点的位置,左侧的三角形由于只画边不画面,所以A点它是不画的,所以就没有Z值来与右侧的三角形的A点的Z值做比较,因此就没法判断A点是谁在前谁在后。 HLR算法总结 Raycasting(光线投射) 算出每条光线在屏幕上某个像素点上的交点位置 在该像素点上只保留最近的交点 Painter’s Algorithm(画家算法) 简单粗暴,先画后面的物体,后画前面的物体,就像画画一样,后涂的颜色会覆盖掉先涂的颜色。 比较两个物体,当前视角来看,如果A的点全都在B的点前面,那么先画B再画A 但缺点也很明显: 1)如果A的点不全的B的前面,即A有些点从当前视角看是在B的某些点后面,就会失败。 2)物体之间有相交的面时,会失败。 (好像飞机的雷达显示是用的这个算法?) Warnock Algorithm (沃诺克算法) 核心:分而治之 不停的四分屏幕(一般是四分,也可以二分或者其他分),直到被细分的子空间只存在简单的前后关系(就是画家算法的那个要求),或者子空间已经细分到了一个像素点的大小。 在曲面和抗锯齿中很有用。 1)当前子空间没有多边形:完成! 2)当前子空间只有一个多边形:画! 3

Using JsonUtility.FromJson to deserialize JSON in Unity

谁都会走 提交于 2020-12-29 12:20:29
问题 This is my sample JSON: {"data":[{"id":141,"layoutLabel":"Sameer","hasCustomProb":1}, {"id":214,"layoutLabel":"abc","hasCustomProb":0}],"status":200} This is the class I made [System.Serializable] public class PlayerInfo { public string [] data; public int status; } This is how I get "status" from JSON: PlayerInfo P = JsonUtility.FromJson<PlayerInfo>(json); Debug.Log(P.status) //returns 200 Can someone help me out can I get and save the data array or maybe get data.id and data.hasCustomProb?

Using JsonUtility.FromJson to deserialize JSON in Unity

独自空忆成欢 提交于 2020-12-29 12:17:52
问题 This is my sample JSON: {"data":[{"id":141,"layoutLabel":"Sameer","hasCustomProb":1}, {"id":214,"layoutLabel":"abc","hasCustomProb":0}],"status":200} This is the class I made [System.Serializable] public class PlayerInfo { public string [] data; public int status; } This is how I get "status" from JSON: PlayerInfo P = JsonUtility.FromJson<PlayerInfo>(json); Debug.Log(P.status) //returns 200 Can someone help me out can I get and save the data array or maybe get data.id and data.hasCustomProb?

Unity实现简单的AR

泄露秘密 提交于 2020-12-28 07:31:30
,本篇是我在博客园上第一次写随笔,有什么不对或者问题可以在评论区留言告诉我哈! 关于AR(增强现实技术(Augmented Reality))简单的概念,在这里就不说了,有兴趣的同学可以上网详细了解,今天我的目的也是让自己复习一下关于AR的知识,还有就是让新接触Unity的小伙伴也可以体验一下,跟着我的步骤走,自己实现是没问题的,接下来正文. 第一步:打开网页,进入Vuforia官网: https://developer.vuforia.com/home-page ,也可以直接百度,第一条就是,点击进入, 第二步:进入官网,点击图示中的Develop,进入后会提示登陆,有账号的小伙伴可以直接登陆,没有的自己注册一下(作为21世纪的少年,注册账号应该是必备技能了),然后登陆进入 第三步:进行许可管理注册,依次点击两个蓝色框框中的按钮,获取一个Key, 第四步:按下图输入App名称,同意条款,确定 第五步,选择项目名称,点击 第六步:生成许可密钥,在Unity工程中需要,即下图红色框框中的一连串, 第七步:创建Database 第八步:输入名称,类型选择第一个就可以,创建 第九步:点击创建好的 第十步:添加Target(Target为所识别的图片文件,格式为.jpg或者.png),选择一张对比度清晰、识别度高的图片。图片名称必须为英文 也可以将图片替换成3D物体或者其他