当前位置:网站首页>Shader Graph learns various special effects cases
Shader Graph learns various special effects cases
2022-08-10 02:12:00 【Wang Yuanjun】
文章目录
前言
打开unity的PackgeManager 安装ShaderGraph 和 UniversalRP ,If using the HD rendering pipeline 需要安装HighDefinitionRP, After all installed 通过菜单 Assets–Create --RenderingCreate a render pipeline configuration
注:如果没有Rendering 是因为没有安装UniversalRP
ShaderGraph基本介绍
All nodes are explained in detail
Then set up the render pipeline configuration file Editor - Project Setting - Graphics中的Scriptable Render Pipeline Settings
然后就可以创建ShaderGraph
Write your ownShader后 创建 一个材质球,然后把shader拖到材质球上,
Then you can use the shader,If the shader has no effect,Possibly your ownshader没有保存
案例
注:如果在MainPreview No effect on preview,请看一下 Are all parameters the same as in the screenshot,
Unity工程
外发光(2022.8.8)
主要节点:FresnelEffect,
原理:Fresnel Effect,菲涅耳效应,根据观察角度产生不同反射率从而对表面效果产生影响,当你靠近时,会反射更多的光.菲涅耳效应节点通过计算表面法线与视线方向的夹角来近似.这个角度越大,返回值越大.这种效果经常被用来实现边缘照明,这在很多艺术风格中都很常见
进阶 Outer glow with direction(2022.8.9)

裁剪(2022.8.9)
主要节点:Position 、AlphaClip
原理:AlphaClip的值如果比Alpha的值大,则会不显示
注意:一定要调PBR Master面板的Alpha参数,Otherwise, the effect will not be displayed
进阶 Cropped with edge color(2022.8.9)
进阶:在裁剪的基础上添加裁剪边缘光
首先利用Smoothstep做出一个边缘渐变
Smoothstep:如果输入In的值分别在输入Edge1和Edge2的值之间,则返回0和1之间的平滑Hermite插值的结果.如果输入In的值小于输入Step1的值,则返回0;如果大于输入Step2的值,则返回1

溶解(2022.8.9)
主要节点 SimpleNoise
注意:一定要调PBR Master面板的Alpha参数,Otherwise, the effect will not be displayed
进阶 Dissolves with edge color(2022.8.9)
溶解边缘添加发光,原理就是对Noise噪声做两个Step,然后相减,再乘个颜色,连到Emission发光节点上
cartoon shadow(2022.8.9)
主要节点NormalVector、DotProduct、SampleGradient
原理:使用Sample Gradient设置几个阴影色块颜色
水波纹(2022.8.9)
主要节点 TillingAndOffset 、Lerp
原理:通过Tilling And Offset节点的Offset来控制水纹的UV偏移,然后再使用Lerp将水纹和主贴图做一个线性差值
积雪效果(2022.8.9)
主要节点 NomalVector 、DotProduct
原理:使用一个向上的 Vector3和 模型的 Normal Vertor(法线向量) 点乘,得到的是 一个标量,表示模型法线向量和垂直向量的夹角(方向的相似度),然后通过 Step过滤得到要显示白色的部分,将要显示的 白色部分再和一个噪声相乘后输入到Master的Emission发光槽中.
不锈钢效果(2022.8.9)
主要节点 ViewDirection.、TillingAndOffset、SimpleNoise
原理:由View Direction视角移动, 引发Tilling And Offset 节点 移动 贴图,产生的效果.注意View Direction使用Tangent切线空间.该效果也可用于冰晶效果.
借鉴链接
https://blog.csdn.net/m0_46378049/article/details/115000628
https://blog.csdn.net/linxinfa/article/details/108049048
边栏推荐
- 分析 20 个 veToken 生态系统协议 这种代币模型为何受欢迎?
- Mysql database ALTER basic operations
- flask——请求、响应、请求扩展、session、闪现、蓝图、g对象、flask-session
- ASEMI整流桥GBJ1010参数,GBJ1010规格,GBJ1010封装
- -骑士巡游-
- 数据的存储——C语言
- 五种定位——粘性定位
- 这一次,话筒给你:向自由软件之父 Richard M. Stallman 提问啦!
- PEG derivative Biotin-PEG1-OH (cas: 95611-10-2, 2-biotinaminoethanol) advantage description
- el-input保留一位小数点
猜你喜欢

flask——请求、响应、请求扩展、session、闪现、蓝图、g对象、flask-session

CAS:851113-28-5 (Biotin-ahx-ahx-tyramine)

CAS:183896-00-6 (Biotin-PEG3-C3-NH2) PEG衍生物

How to add control panel to right click menu in win7

GB28181 sip和RTSP(Real-Time Streaming Protocol)实时流控制协议

Biotin-Cy2 Conjugate, Biotin-Cy2 Conjugate_Cy2 Biotin Conjugate

基于Web的疫情隔离区订餐系统

对修饰器的实验支持功能在将来的版本中可能更改。在 “tsconfig“ 或 “jsconfig“ 中设置 “experimentalDecorators“ 选项以删除此警告

How to turn off system protection in Win11?How to turn off the system protection restore function?

分析 20 个 veToken 生态系统协议 这种代币模型为何受欢迎?
随机推荐
【LeetCode】求根节点到叶节点数字之和
防勒索病毒现状分析
罗彻斯特大学 | 现在是什么序列?蛋白质序列的贝叶斯优化的预训练集成
Stanford CS143 速通PA1教程
Involved in PEG-Biotin (CAS: 1778736-18-7) Biotin-PEG4-OH is widely used in molecular target detection
CAS:183896-00-6 (Biotin-PEG3-C3-NH2) PEG衍生物
How to activate the payment function on WeChat official account?
宽带由20M换为100M
头脑风暴:单词拆分
-红与黑-
Mysql database ALTER basic operations
365天挑战LeetCode1000题——Day 052 逐步求和得到正数的最小值 贪心
-向量点积-
ASEMI整流桥GBJ1010参数,GBJ1010规格,GBJ1010封装
-骑士巡游-
快速响应性智能型/智能响应性聚乙二醇纳米/还原响应型水凝胶的研究与制备
Pagoda measurement - building LightPicture open source map bed system
shell指定参数名传参
-采花生-
R语言使用glm函数构建logistic回归模型,使用forestmodel包的forest_model函数可视化逻辑回归模型对应的森林图