Shaders

1、Vertex-Lit,顶点光照着色器。

  Vertex-Lit is one of the simplest shaders. All lights shining on it are rendered in a single pass and calculated at vertices only. Because it is vertex-lit, it won't display any pixel-based rendering effects, such as light cookies, normal mapping, or shadows. This shader is also much more sensitive to tesselation of the models.

   If you put a point light very close to a cube using this shader, the light will only be calculated at the corners. Pixel-lit shaders are much more effective at creating a nice round highlight, independent of tesselation. If that's an effect you want, you may consider using a pixel-lit shader or increase tesselation of the objects instead.

2、Shader的性能。

  Performance of a shader mostly depends on two things: shader itself and which Rendering Path is used by the project or specific camera. 

  1)Rendering Paths and shader performance

  Deferred Lighting and Vertex Lit paths have the most predictable performance. In Deferred lighting, each object is generally drawn twice, no matter what lights are affecting it. Similarly, in Vertex Lit each object is generally drawn once. So then, the performance differences in shaders mostly depend on how many textures they use and what calculations they do.

  2)Shader Performance in Forward rendering path

  

Shaders的更多相关文章

  1. Vuforia结合Skyshop: Image-Based Lighting Tools & Shaders插件实现真实的光照效果

    Skyshop: Image-Based Lighting Tools & Shaders 插件地址:https://www.assetstore.unity3d.com/en/#!/cont ...

  2. Unity Shaders 第一个默认程序分析

    Unity Shaders 第一个默认程序 Shader "Custom/Shader" { Properties { _MainTex ("Base (RGB)&quo ...

  3. Shaders(读书笔记4 --- Real-Time rendering)

    1. vertex,pixel以及geometry shaders共享一个programming model,即common-shader core,在GPU架构中的unified shader可以和 ...

  4. 顶点着色器详解 (Vertex Shaders)

    学习了顶点处理,你就知道固定功能流水线怎么将顶点从模型空间坐标系统转化到屏幕空间坐标系统.虽然固定功能流水线也可以通过设置渲染状态和参数来改变最终输出的结果,但是它的整体功能还是受限.当我们想实现一个 ...

  5. Unity Shaders and Effets Cookbook

    Unity Shaders and Effects Cookbook 最近在读 <Unity Shaders and Effects Cookbook> 中文名称:<Unity 着色 ...

  6. A trip through the Graphics Pipeline 2011_13 Compute Shaders, UAV, atomic, structured buffer

    Welcome back to what’s going to be the last “official” part of this series – I’ll do more GPU-relate ...

  7. A trip through the Graphics Pipeline 2011_10_Geometry Shaders

    Welcome back.     Last time, we dove into bottom end of the pixel pipeline. This time, we’ll switch ...

  8. Unity Shader——Writing Surface Shaders(3)——Surface Shader Lighting Examples

    Surface Shader 光照例子 这里有一些自定义光照模型和Surface Shaders的例子.通常的Surface Shader例子在这里. 由于延迟光照在某些自定义的逐材质光照模型中表现得 ...

  9. Unity Shader——Writing Surface Shaders(2)——Custom Lighting models in Surface Shaders

    Surface Shader中的自定义光照模型 当你在编写 Surface Shaders 时,是在描述一个表面的属性(反射颜色.法线……),而且光的交互过程是由一个光照模型来计算的.内建的光照模型有 ...

  10. Unity Shader——Writing Surface Shaders(0)

    从今天起,开始翻译Unity关于shader的官方文档.翻译水平比较一般,目的主要是通过翻译来提升对shader的见解,也让其他人更容易的了解shader.以下开始正文内容: 编写Surface Sh ...

随机推荐

  1. BZOJ AC倒序总结

    https://fcw.moe/?p=177

  2. 用Python做图像处理

    转自:http://blog.csdn.net/gzlaiyonghao/article/details/1852726  最近在做一件比较 evil 的事情——验证码识别,以此来学习一些新的技能.因 ...

  3. 日志框架--(二)JDK Logging

    前言 从jdk1.4起,JDK开始自带一套日志系统.JDK Logger最大的优点就是不需要任何类库的支持,只要有Java的运行环境就可以使用.相对于其他的日志框架,JDK自带的日志可谓是鸡肋,无论易 ...

  4. 在debian上安装最新版erlang

    参考这里https://www.erlang-solutions.com/downloads/download-erlang-otp 源码安装的无视 sudo gvim /etc/apt/source ...

  5. LWIP在STM32实现

    http://www.openedv.com/posts/list/25178.htm

  6. [Java.web][eclipse]经验集

    自动提示部分内容来自:http://www.cnblogs.com/mashuangying2016/p/6549991.html 使用 Eclipse 调试 Tomcat 的设置: Window - ...

  7. Android中preference标签的使用

    现在做公司任务的时候,经常会要去读Settings的源码,然后发现在xml文件中几乎全是用的preferenceScreen和preferenceCategory标签,很少有用布局和控件的,然后我就自 ...

  8. canvas之画圆

    <canvas id="canvas" width="500" height="500" style="background ...

  9. html5的canvas方法的总结

    canvas的方法 save()保存当前环境的状态 restore() 返回之前保存过的路径状态和属性 createEvent() getContext()返回一个对象,指出访问绘图功能必要的API ...

  10. C++ 栈 (数组实现)

    上一篇用链表实现了stack,这篇我们采用数组来存储数据,数组更容易理解,直接贴代码 第一.代码实现 #pragma once #include <iostream> using name ...