highlight

Unity中实现网格轮廓效果,选中边框效果(附带高斯模糊实现模式,处理了锯齿情况)

血红的双手。 提交于 2020-05-08 06:30:48
问题背景: 最近要实现选中实体的高亮效果,要那种类似于unity中Outline的效果,网格轮廓高亮效果。 效果图: 具体代码: OutlineEffect.cs 实体高亮效果类: 轮廓边总控制类,该脚本需要挂载到场景相机上 1 using UnityEngine; 2 using System.Collections.Generic; 3 using UnityEngine.Rendering; 4 5 namespace Tx3d.Framework 6 { 7 [DisallowMultipleComponent] 8 [RequireComponent( typeof (Camera))] 9 [ExecuteInEditMode] 10 public class OutlineEffect : MonoBehaviour 11 { 12 public static OutlineEffect Instance { get ; private set ; } 13 14 private readonly LinkedSet<Outline> outlines = new LinkedSet<Outline> (); 15 16 [Range( 1.0f , 6.0f )] 17 public float lineThickness = 1.0f ; 18 [Range( 0

【vue】使用vue+element搭建项目,Tree树形控件使用

半世苍凉 提交于 2020-05-07 17:39:14
目录 一、 安装依赖 二、 常用属性、事件 三、 demo应用    html代码 属性用法 3.2.1 :default-expanded-keys(默认展开项) 3.2.2 :props= "defaultProps" 用法 3.2.3 通过render-content方法定义树节点内容(js代码) 3.2.4 :load="loadChildData" (load 加载子树数据的方法,仅仅当lazy属性为true时生效) (js代码) 3.2.5 @node-click="handleNodeClick" 3.2.6 更新二级数据 3.2.7 接口情况 3.2.8 页面效果图: 一 、安装依赖 本例中,使用render-content进行树节点内容的自定义,因此需要支持JSX语法。(见参考资料第3个) 在Git bash中运行一下指令 cnpm install\ babel-plugin-syntax-jsx\ babel-plugin-transform-vue-jsx\ babel-helper-vue-jsx-merge-props\ babel-preset-es2015\ --save-dev 二、常用属性、事件 常用属性 Attributes(属性名) 描述 type(类型) default(默认值) node-key 每个树节点用来作为唯一标识的属性,

Elasticsearch学习之图解Elasticsearch中的_source、_all、store和index属性

三世轮回 提交于 2020-05-05 15:58:56
转自 : https://blog.csdn.net/napoay/article/details/62233031 1. 概述 Elasticsearch中有几个关键属性容易混淆,很多人搞不清楚_source字段里存储的是什么?store属性的true或false和_source字段有什么关系?store属性设置为true和_all有什么关系?index属性又起到什么作用?什么时候设置store属性为true?什么时候应该开启_all字段?本文通过图解的方式,深入理解Elasticsearch中的_source、_all、store和index属性。 如图1所示, 第二象限是一份原始文档,有title和content2个字段,字段取值分别为”我是中国人”和” 热爱”,这一点没什么可解释的。我们把原始文档写入Elasticsearch,默认情况下,Elasticsearch里面有2份内容,一份是原始文档,也就是_source字段里的内容,我们在Elasticsearch中搜索文档,查看的文档内容就是_source中的内容,如图2,相信大家一定非常熟悉这个界面。 另一份是倒排索引,倒排索引中的数据结构是倒排记录表,记录了词项和文档之间的对应关系,比如关键词”中国人”包含在文档ID为1的文档中,倒排记录表中存储的就是这种对应关系,当然也包括词频等更多信息

cesium 3dtiles模型单体化点击高亮效果

走远了吗. 提交于 2020-05-04 20:59:27
前言 cesium 官网的api文档介绍地址 cesium官网api ,里面详细的介绍 cesium 各个类的介绍,还有就是在线例子: cesium 官网在线例子 ,这个也是学习 cesium 的好素材。 cesium官网在线例子 https://sandcastle.cesium.com/?src=3D+Tiles+Feature+Picking.html 大概思路如下: 加载3dtiles模型 var tileset = new Cesium.Cesium3DTileset({ url: Cesium.IonResource.fromAssetId( 75343 ), }); viewer.scene.primitives.add(tileset); 创建html元素,鼠标移动以及点击模型高亮作用 // HTML overlay for showing feature name on mouseover var nameOverlay = document.createElement("div" ); viewer.container.appendChild(nameOverlay); nameOverlay.className = "backdrop" ; nameOverlay.style.display = "none" ; nameOverlay.style

cesium 3dtiles模型单体化点击高亮效果

泄露秘密 提交于 2020-05-04 19:30:11
前言 cesium 官网的api文档介绍地址 cesium官网api ,里面详细的介绍 cesium 各个类的介绍,还有就是在线例子: cesium 官网在线例子 ,这个也是学习 cesium 的好素材。 cesium官网在线例子 https://sandcastle.cesium.com/?src=3D+Tiles+Feature+Picking.html 大概思路如下: 加载3dtiles模型 var tileset = new Cesium.Cesium3DTileset({ url: Cesium.IonResource.fromAssetId( 75343 ), }); viewer.scene.primitives.add(tileset); 创建html元素,鼠标移动以及点击模型高亮作用 // HTML overlay for showing feature name on mouseover var nameOverlay = document.createElement("div" ); viewer.container.appendChild(nameOverlay); nameOverlay.className = "backdrop" ; nameOverlay.style.display = "none" ; nameOverlay.style

Unity中实现网格轮廓效果,选中边框效果(附带高斯模糊实现模式,处理了锯齿情况)

依然范特西╮ 提交于 2020-05-03 17:47:05
问题背景: 最近要实现选中实体的高亮效果,要那种类似于unity中Outline的效果,网格轮廓高亮效果。 效果图: 具体代码: OutlineEffect.cs 实体高亮效果类: 轮廓边总控制类,该脚本需要挂载到场景相机上 1 using UnityEngine; 2 using System.Collections.Generic; 3 using UnityEngine.Rendering; 4 5 namespace Tx3d.Framework 6 { 7 [DisallowMultipleComponent] 8 [RequireComponent( typeof (Camera))] 9 [ExecuteInEditMode] 10 public class OutlineEffect : MonoBehaviour 11 { 12 public static OutlineEffect Instance { get ; private set ; } 13 14 private readonly LinkedSet<Outline> outlines = new LinkedSet<Outline> (); 15 16 [Range( 1.0f , 6.0f )] 17 public float lineThickness = 1.0f ; 18 [Range( 0

Unity中实现网格轮廓效果,选中边框效果(附带高斯模糊实现模式,处理了锯齿情况)

。_饼干妹妹 提交于 2020-05-03 17:41:55
问题背景: 最近要实现选中实体的高亮效果,要那种类似于unity中Outline的效果,网格轮廓高亮效果。 效果图: 具体代码: OutlineEffect.cs 实体高亮效果类: 轮廓边总控制类,该脚本需要挂载到场景相机上 1 using UnityEngine; 2 using System.Collections.Generic; 3 using UnityEngine.Rendering; 4 5 namespace Tx3d.Framework 6 { 7 [DisallowMultipleComponent] 8 [RequireComponent( typeof (Camera))] 9 [ExecuteInEditMode] 10 public class OutlineEffect : MonoBehaviour 11 { 12 public static OutlineEffect Instance { get ; private set ; } 13 14 private readonly LinkedSet<Outline> outlines = new LinkedSet<Outline> (); 15 16 [Range( 1.0f , 6.0f )] 17 public float lineThickness = 1.0f ; 18 [Range( 0

Unity中实现网格轮廓效果,选中边框效果(附带高斯模糊实现模式,处理了锯齿情况)

你。 提交于 2020-05-03 17:26:00
问题背景: 最近要实现选中实体的高亮效果,要那种类似于unity中Outline的效果,网格轮廓高亮效果。 效果图: 具体代码: OutlineEffect.cs 实体高亮效果类: 轮廓边总控制类,该脚本需要挂载到场景相机上 1 using UnityEngine; 2 using System.Collections.Generic; 3 using UnityEngine.Rendering; 4 5 namespace Tx3d.Framework 6 { 7 [DisallowMultipleComponent] 8 [RequireComponent( typeof (Camera))] 9 [ExecuteInEditMode] 10 public class OutlineEffect : MonoBehaviour 11 { 12 public static OutlineEffect Instance { get ; private set ; } 13 14 private readonly LinkedSet<Outline> outlines = new LinkedSet<Outline> (); 15 16 [Range( 1.0f , 6.0f )] 17 public float lineThickness = 1.0f ; 18 [Range( 0

Unity中实现网格轮廓效果,选中边框效果(附带高斯模糊实现模式,处理了锯齿情况)

江枫思渺然 提交于 2020-05-03 17:12:04
问题背景: 最近要实现选中实体的高亮效果,要那种类似于unity中Outline的效果,网格轮廓高亮效果。 效果图: 具体代码: OutlineEffect.cs 实体高亮效果类: 轮廓边总控制类,该脚本需要挂载到场景相机上 1 using UnityEngine; 2 using System.Collections.Generic; 3 using UnityEngine.Rendering; 4 5 namespace Tx3d.Framework 6 { 7 [DisallowMultipleComponent] 8 [RequireComponent( typeof (Camera))] 9 [ExecuteInEditMode] 10 public class OutlineEffect : MonoBehaviour 11 { 12 public static OutlineEffect Instance { get ; private set ; } 13 14 private readonly LinkedSet<Outline> outlines = new LinkedSet<Outline> (); 15 16 [Range( 1.0f , 6.0f )] 17 public float lineThickness = 1.0f ; 18 [Range( 0

TypeScript: type alias 与 interface

爱⌒轻易说出口 提交于 2020-05-02 18:26:56
<table class="d-block"> <tbody class="d-block"> <tr class="d-block"> <td class="d-block comment-body markdown-body js-comment-body"> <p>官方文档中有关于两者对比的信息,隐藏在 TypeScript Handbook 中,见 <a href="https://www.typescriptlang.org/docs/handbook/advanced-types.html" rel="nofollow"><code>Interfaces vs. Type Aliases</code></a> 部分。</p> <p>但因为这一部分很久没更新了,所以其中描述的内容不一定全对。</p> <p>比如,</p> <h3>区别点之一:Type Alias 不会创建新的类型,体现在错误信息上。</h3> <blockquote> <p>One difference is, that interfaces create a new name that is used everywhere. Type aliases don’t create a new name — for instance, error messages won’t use the alias