Unity Manual


  • 首页

  • 分类

  • 公益404

  • 搜索

Procedural Materials

发表于 2017-07-04 | 更新于 2017-07-04 | 分类于 Graphics , Graphics Overview , Procedural Materials , Procedural Materials

Procedural Materials

  • 物理材质本质上和标准的材质是相同的
  • 唯一的区别是可以使用运行时生成的纹理

Asynchronous Texture Upload

发表于 2017-07-03 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , Asynchronous Texture Upload

Asynchronous Texture Upload

  • Asynchronous Texture Upload enables asynchronous loading of Texture Data from disk and enables time-sliced upload to GPU on the Render-thread
  • 对于没有开启读写的纹理,这个是自动开启的
  • 目测不支持AB,所以并没卵用

Simple & Full Control Over Memory / Time-Slicing

  • 在 QualitySettings 里面可以设置异步提交时间和 Buffer 大小

CullingGroup API

发表于 2017-07-03 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , CullingGroup API

CullingGroup API

  • CullingGroup offers a way to integrate your own systems into Unity’s culling and LOD pipeline.

CullingGroup API Best Practices

Using visibility

Using distance

Performance and design


Graphics hardware capabilities and emulation

发表于 2017-07-03 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , Graphics hardware capabilities and emulation

Graphics hardware capabilities and emulation

  • Edit > Graphics Emulation,可以模拟显卡,支持模拟哪些,还得看显卡的支持
  • 列出了不同显卡支持功能

Shader Model 4 (Standalone & Windows Store platforms)

Shader Model 3 (Standalone platform)

Shader Model 2 (Standalone platform)

OpenGL ES 3.0 (Android platform)

Metal (iOS, tvOS platforms)

OpenGL ES 2.0 (Android, iOS, tvOS, Tizen platforms)

WebGL 1 and WebGL 2 (WebGL platform)

Shader Model 2 - DX11 FL9.3 (Windows Store Platform)


Sparse Textures

发表于 2017-07-03 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , Sparse Textures

Sparse Textures

  • 支持的设备需求不太明确

GPU instancing

发表于 2017-07-03 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , GPU instancing

GPU instancing

Introduction

  • 选多同一个 mesh 多次在同一时刻,牺牲一点 draw call
  • 虽然是渲染同一个 mesh,但是可以有不同的参数

Adding instancing to your Materials

GPU Instancing is available on the following platforms and APIs:

  • DirectX 11 and DirectX 12 on Windows
  • OpenGL Core 4.1+/ES3.0+ on Windows, macOS, Linux, iOS and Android
  • Metal on macOS and iOS
  • Vulkan on Windows and Android
  • PlayStation 4 and Xbox One
  • WebGL (requires WebGL 2.0 API)

Advanced GPU instancing tips

Batching priority

  • 优先顺序:静态合并 -》GPU Instancing -》动态合并

UnityObjectToClipPos

  • 这玩意效率更高,比起自己写转换

Further notes

  • For Graphics.DrawMeshInstanced, you need to enable GPU Instancing on the Material that is being passed into this method. However, Graphics.DrawMeshInstancedIndirect does not require you to enable GPU Instancing. The indirect instancing keyword PROCEDURAL_INSTANCING_ON is not affected by stripping.
  • Instanced draw calls appear in the Frame Debugger as Draw Mesh (instanced).
  • When using forward rendering, Unity cannot efficiently instance objects that are affected by multiple lights. Only the base pass can make effective use of instancing, not the added passes. For more information about lighting passes, see documentation on Forward Rendering and Pass Tags
  • Objects that use lightmaps, or are affected by different light or Reflection Probes, can’t be instanced.
  • If you have more than two passes for multi-pass Shaders, only the first passes can be instanced. This is because Unity forces the later passes to be rendered together for each object, forcing Material changes.

Compute shaders

发表于 2017-07-01 | 更新于 2017-07-03 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , Compute shaders

Compute shaders

  • compute shaders 跑在显卡上,在正常的渲染管线之外
  • 主要用于大量的并行运算
  • Windows and Windows Store, with a DirectX 11 or DirectX 12 graphics API and Shader Model 5.0 GPU
  • macOS and iOS using Metal graphics API
  • Android, Linux and Windows platforms with Vulkan API
  • Modern OpenGL platforms (OpenGL 4.3 on Linux or Windows; OpenGL ES 3.1 on Android). Note that Mac - OS X does not support OpenGL 4.3
  • Modern consoles (Sony PS4 and Microsoft Xbox One)

Rendering Paths

发表于 2017-07-01 | 更新于 2017-07-01 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , Rendering Paths

Rendering Paths

Rendering Paths Comparison

Deferred Forward Legacy Deferred Vertex Lit
Features
Per-pixel lighting (normal maps, light cookies) Yes Yes Yes -
Realtime shadows Yes With caveats Yes -
Reflection Probes Yes Yes - -
Depth&Normals Buffers Yes Additional render passes Yes -
Soft Particles Yes - Yes -
Semitransparent objects - Yes - Yes
Anti-Aliasing - Yes - Yes
Light Culling Masks Limited Yes Limited Yes
Lighting Fidelity All per-pixel Some per-pixel All per-pixel All per-vertex
Performance
Cost of a per-pixel Light Number of pixels it illuminates Number of pixels * Number of objects it illuminates Number of pixels it illuminates -
Number of times objects are normally rendered 1 Number of per-pixel lights 2 1
Overhead for simple scenes High None Medium None
Platform Support
PC (Windows/Mac) Shader Model 3.0+ & MRT All Shader Model 3.0+ All
Mobile (iOS/Android) OpenGL ES 3.0 & MRT All OpenGL ES 2.0 All
Consoles XB1, PS4 All XB1, PS4, 360 -


High Dynamic Range Rendering

发表于 2017-07-01 | 更新于 2017-07-01 | 分类于 Graphics , Graphics Overview , Advanced Rendering Features , High Dynamic Range Rendering

High Dynamic Range Rendering

  • 正常渲染下,0代表最小,1代表最大
  • 然而显示场景,人眼倾向于适应环境光照
  • 因此白色物体在光亮的地方没有在灰暗的地方显得那么亮
  • 人眼对于低光场景更为敏感
  • 尽管使用 HDR,最终还是会将值调整为显示设备可用的范围
  • 本质是让显卡内部支持用0-1之外的范围表示颜色

Advantages of HDR

  • 高光环境颜色不会丢失

Disadvantages of HDR

  • 使用浮点渲染纹理(渲染变慢,并且需要更多的内存)
  • 不支持反锯齿
  • 不是所有的硬件都支持

Post-processing stack

发表于 2017-07-01 | 更新于 2017-07-01 | 分类于 Graphics , Graphics Overview , Post-processing overview , Post-processing stack

Post-processing stack

  • 能将特效都在单通道上处理

Effects

  • Anti-aliasing (FXAA & TAA)
  • Ambient Occlusion
  • Screen Space Reflection
  • Fog
  • Depth of Field
  • Motion Blur
  • Eye Adaptation
  • Bloom
  • Color Grading
  • User Lut
  • Chromatic Aberration
  • Grain
  • Vignette
  • Dithering

1…567
Fly

Fly

作者懒得写

69 日志
113 分类
GitHub CSDN
© 2018 Fly
由 Hexo 强力驱动
主题 - NexT.Pisces
0%